/*! * devextreme-angular-test * Version: 17.2.8 * Build date: Mon Feb 05 2018 * * Copyright (c) 2012 - 2018 Developer Express Inc. ALL RIGHTS RESERVED * * This software may be modified and distributed under the terms * of the MIT license. See the LICENSE file in the root of the project for details. * * https://github.com/DevExpress/devextreme-angular */ import { Component, NgModule, Host, SkipSelf, Input, ContentChildren, forwardRef, QueryList } from '@angular/core'; import { NestedOptionHost } from '../../core/nested-option'; import { CollectionNestedOption } from '../../core/nested-option'; import { DxiLocationComponent } from './location-dxi'; @Component({ selector: 'dxi-route', template: '', styles: [''], providers: [NestedOptionHost] }) export class DxiRouteComponent extends CollectionNestedOption { @Input() get color(): string { return this._getOption('color'); } set color(value: string) { this._setOption('color', value); } @Input() get locations(): Array { return this._getOption('locations'); } set locations(value: Array) { this._setOption('locations', value); } @Input() get mode(): string { return this._getOption('mode'); } set mode(value: string) { this._setOption('mode', value); } @Input() get opacity(): number { return this._getOption('opacity'); } set opacity(value: number) { this._setOption('opacity', value); } @Input() get weight(): number { return this._getOption('weight'); } set weight(value: number) { this._setOption('weight', value); } protected get _optionPath() { return 'routes'; } @ContentChildren(forwardRef(() => DxiLocationComponent)) get locationsChildren(): QueryList { return this._getOption('locations'); } set locationsChildren(value) { this.setChildren('locations', value); } constructor(@SkipSelf() @Host() parentOptionHost: NestedOptionHost, @Host() optionHost: NestedOptionHost) { super(); parentOptionHost.setNestedOption(this); optionHost.setHost(this, this._fullOptionPath.bind(this)); } } @NgModule({ declarations: [ DxiRouteComponent ], exports: [ DxiRouteComponent ], }) export class DxiRouteModule { }