NavigationCancel

Stable Class What it does Represents an event triggered when a navigation is canceled. Class Overview class NavigationCancel { constructor(id: number, url: string, reason: string) id : number url : string reason : string toString() : string } Class Description Constructor constructor(id: number, url: string, reason: string) Class Details id : number url : string reason : string toString() : string exported from @angular/router/index, defined in @angular/router/src/r

NavigationError

Stable Class What it does Represents an event triggered when a navigation fails due to an unexpected error. Class Overview class NavigationError { constructor(id: number, url: string, error: any) id : number url : string error : any toString() : string } Class Description Constructor constructor(id: number, url: string, error: any) Class Details id : number url : string error : any toString() : string exported from @angular/router/index, defined in @angular/router/s

MockLocationStrategy

Stable Class Class Overview class MockLocationStrategy { constructor() internalBaseHref : string internalPath : string internalTitle : string urlChanges : string[] simulatePopState(url: string) : void path(includeHash?: boolean) : string prepareExternalUrl(internal: string) : string pushState(ctx: any, title: string, path: string, query: string) : void replaceState(ctx: any, title: string, path: string, query: string) : void onPopState(fn: (value: any) => void)

NavigationExtras

Stable Interface What it does Represents the extra options used during navigation. Interface Overview interface NavigationExtras { relativeTo : ActivatedRoute queryParams : Params fragment : string preserveQueryParams : boolean preserveFragment : boolean skipLocationChange : boolean replaceUrl : boolean } Interface Description Interface Details relativeTo : ActivatedRoute Enables relative navigation from the current ActivatedRoute. Configuration: [{ path: 'parent', co

ModuleWithProviders

Stable Interface Interface Overview interface ModuleWithProviders { ngModule : Type<any> providers : Provider[] } Interface Description A wrapper around a module that also includes the providers. Interface Details ngModule : Type<any> providers : Provider[] exported from @angular/core/index, defined in @angular/core/src/metadata/ng_module.ts

MetadataOverride

Experimental Type-alias Interface Overview interface MetadataOverride { } Interface Description exported from @angular/core/testing/index, defined in @angular/core/testing/metadata_override.ts

MinLengthValidator

Stable Directive Class Overview class MinLengthValidator { minlength : string ngOnChanges(changes: SimpleChanges) validate(c: AbstractControl) : {[key: string]: any} registerOnValidatorChange(fn: () => void) } Selectors [minlength][formControlName] [minlength][formControl] [minlength][ngModel] Class Description A directive which installs the MinLengthValidator for any formControlName, formControl, or control with ngModel that also has a minlength attribute. Class Details min

MockBackend

Experimental Class Class Overview class MockBackend { constructor() connections : any connectionsArray : MockConnection[] pendingConnections : any verifyNoPendingRequests() resolveAllConnections() createConnection(req: Request) : MockConnection } Class Description A mock backend for testing the Http service. This class can be injected in tests, and should be used to override providers to other backends, such as XHRBackend. Example import {BaseRequestOptions, Http} from

MessageBusSource

Experimental Interface Interface Overview interface MessageBusSource { initChannel(channel: string, runInZone: boolean) : void attachToZone(zone: NgZone) : void from(channel: string) : EventEmitter<any> } Interface Description Interface Details initChannel(channel: string, runInZone: boolean) : void Sets up a new channel on the MessageBusSource. MUST be called before calling from on the channel. If runInZone is true then the source will emit events inside the angular zone. if

MockConnection

Experimental Class Class Overview class MockConnection { constructor(req: Request) readyState : ReadyState request : Request response : ReplaySubject<Response> mockRespond(res: Response) mockDownload(res: Response) mockError(err?: Error) } Class Description Mock Connection to represent a Connection for tests. Constructor constructor(req: Request) Class Details readyState : ReadyState Describes the state of the connection, based on XMLHttpRequest.readyState, bu