Skip to content

Commit 7bca101

Browse files
docs(*): move files into proper docs modules
1 parent d849df6 commit 7bca101

File tree

5 files changed

+22
-0
lines changed

5 files changed

+22
-0
lines changed

src/hooks/lazyLoadStates.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/** @module hooks */ /** */
12
import {Transition} from "../transition/transition";
23
import {TransitionService} from "../transition/transitionService";
34
import {TransitionHookFn} from "../transition/interface";

src/ng2/lazyLoadNgModule.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/** @module ng2 */ /** */
12
import {Transition} from "../transition/transition";
23
import {NG2_INJECTOR_TOKEN, Ng2StateDeclaration} from "./interface";
34
import {UIROUTER_STATES_TOKEN} from "./uiRouterNgModule";

src/ng2/mergeInjector.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
1+
/** @module ng2 */ /** */
12
import {Injector} from "@angular/core";
23

4+
/**
5+
* Merge two injectors
6+
*
7+
* This class implements the Injector ng2 interface but delegates
8+
* to the Injectors provided in the constructor.
9+
*/
310
export class MergeInjector implements Injector {
411
static NOT_FOUND = {};
512
private injectors: Injector[];
@@ -8,6 +15,17 @@ export class MergeInjector implements Injector {
815
this.injectors = injectors;
916
}
1017

18+
/**
19+
* Get the token from the first injector which contains it.
20+
*
21+
* Delegates to the first Injector.get().
22+
* If not found, then delegates to the second Injector (and so forth).
23+
* If no Injector contains the token, return the `notFoundValue`, or throw.
24+
*
25+
* @param token the DI token
26+
* @param notFoundValue the value to return if none of the Injectors contains the token.
27+
* @returns {any} the DI value
28+
*/
1129
get(token: any, notFoundValue?: any): any {
1230
for (let i = 0; i < this.injectors.length; i++) {
1331
let val = this.injectors[i].get(token, MergeInjector.NOT_FOUND);

src/ng2/rx.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/** @module ng2 */ /** */
12
import {Observable, ReplaySubject} from "rxjs/Rx";
23
import {Transition} from "../transition/transition";
34
import {UIRouter} from "../router";

src/ng2/uiRouterNgModule.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/** @module ng2 */ /** */
12
import {Ng2StateDeclaration} from "./interface";
23
import {NgModule, NgModuleMetadataType, OpaqueToken} from "@angular/core";
34
import {_UIROUTER_DIRECTIVES} from "./directives/directives";

0 commit comments

Comments
 (0)