// Type definitions for Angular v2.0.0-alpha.26 // Project: http://angular.io/ // Definitions by: angular team // Definitions: https://github.com/borisyankov/DefinitelyTyped // *********************************************************** // This file is generated by the Angular build process. // Please do not create manual edits or send pull requests // modifying this file. // *********************************************************** // Angular depends transitively on these libraries. // If you don't have them installed you can run // $ tsd query es6-promise rx rx-lite --action install --save /// /// interface List extends Array {} interface Map {} interface StringMap {} interface Type {} declare module "angular2/angular2" { type SetterFn = typeof Function; type int = number; // See https://github.com/Microsoft/TypeScript/issues/1168 class BaseException /* extends Error */ { message: any; stack: any; toString(): string; } } declare module "angular2/angular2" { class AbstractChangeDetector extends ChangeDetector { addChild(cd: ChangeDetector): any; addShadowDomChild(cd: ChangeDetector): any; callOnAllChangesDone(): any; checkNoChanges(): any; detectChanges(): any; detectChangesInRecords(throwOnChange: boolean): any; lightDomChildren: List; markAsCheckOnce(): any; markPathToRootAsCheckOnce(): any; mode: string; parent: ChangeDetector; ref: ChangeDetectorRef; remove(): any; removeChild(cd: ChangeDetector): any; removeShadowDomChild(cd: ChangeDetector): any; shadowDomChildren: List; } class ProtoRecord { args: List; bindingRecord: BindingRecord; contextIndex: number; directiveIndex: DirectiveIndex; expressionAsString: string; fixedArgs: List; funcOrValue: any; isLifeCycleRecord(): boolean; isPipeRecord(): boolean; isPureFunction(): boolean; lastInBinding: boolean; lastInDirective: boolean; mode: number; name: string; selfIndex: number; } class LifecycleEvent { name: string; } interface FormDirective { addControl(dir: ControlDirective): void; addControlGroup(dir: ControlGroupDirective): void; getControl(dir: ControlDirective): Control; removeControl(dir: ControlDirective): void; removeControlGroup(dir: ControlGroupDirective): void; updateModel(dir: ControlDirective, value: any): void; } /** * A directive that contains a group of [ControlDirective]. * * @exportedAs angular2/forms */ class ControlContainerDirective { formDirective: FormDirective; name: string; path: List; } /** * A marker annotation that marks a class as available to `Injector` for creation. Used by tooling * for generating constructor stubs. * * ``` * class NeedsService { * constructor(svc:UsefulService) {} * } * * @Injectable * class UsefulService {} * ``` * @exportedAs angular2/di_annotations */ class Injectable { } /** * Injectable Objects that contains a live list of child directives in the light Dom of a directive. * The directives are kept in depth-first pre-order traversal of the DOM. * * In the future this class will implement an Observable interface. * For now it uses a plain list of observable callbacks. * * @exportedAs angular2/view */ class BaseQueryList { add(obj: any): any; fireCallbacks(): any; onChange(callback: any): any; removeCallback(callback: any): any; reset(newList: any): any; } class AppProtoView { bindElement(parent: ElementBinder, distanceToParent: int, protoElementInjector: ProtoElementInjector, componentDirective?: DirectiveBinding): ElementBinder; /** * Adds an event binding for the last created ElementBinder via bindElement. * * If the directive index is a positive integer, the event is evaluated in the context of * the given directive. * * If the directive index is -1, the event is evaluated in the context of the enclosing view. * * @param {string} eventName * @param {AST} expression * @param {int} directiveIndex The directive index in the binder or -1 when the event is not bound * to a directive */ bindEvent(eventBindings: List, boundElementIndex: number, directiveIndex?: int): void; elementBinders: List; protoChangeDetector: ProtoChangeDetector; protoLocals: Map; render: RenderProtoViewRef; variableBindings: Map; } /** * Const of making objects: http://jsperf.com/instantiate-size-of-object */ class AppView implements ChangeDispatcher, EventDispatcher { callAction(elementIndex: number, actionExpression: string, action: Object): any; changeDetector: ChangeDetector; componentChildViews: List; /** * The context against which data-binding expressions in this view are evaluated against. * This is always a component instance. */ context: any; dispatchEvent(elementIndex: number, eventName: string, locals: Map): boolean; elementInjectors: List; freeHostViews: List; getDetectorFor(directive: DirectiveIndex): any; getDirectiveFor(directive: DirectiveIndex): any; hydrated(): boolean; init(changeDetector: ChangeDetector, elementInjectors: List, rootElementInjectors: List, preBuiltObjects: List, componentChildViews: List): any; /** * Variables, local to this view, that can be used in binding expressions (in addition to the * context). This is used for thing like `