2016-07-28 07:54:49 -04:00
|
|
|
/**
|
|
|
|
* @license
|
|
|
|
* Copyright Google Inc. All Rights Reserved.
|
|
|
|
*
|
|
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
|
|
* found in the LICENSE file at https://angular.io/license
|
|
|
|
*/
|
|
|
|
|
2016-08-10 21:21:28 -04:00
|
|
|
import {Compiler, CompilerOptions, ComponentMetadataType, DirectiveMetadataType, Injector, NgModuleMetadataType, PipeMetadataType} from '../index';
|
2016-07-28 07:54:49 -04:00
|
|
|
import {unimplemented} from '../src/facade/exceptions';
|
2016-08-10 21:21:28 -04:00
|
|
|
import {Type} from '../src/type';
|
2016-07-28 07:54:49 -04:00
|
|
|
import {MetadataOverride} from './metadata_override';
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Special interface to the compiler only used by testing
|
|
|
|
*
|
|
|
|
* @experimental
|
|
|
|
*/
|
|
|
|
export class TestingCompiler extends Compiler {
|
|
|
|
get injector(): Injector { throw unimplemented(); }
|
2016-08-10 21:21:28 -04:00
|
|
|
overrideModule(module: Type<any>, overrides: MetadataOverride<NgModuleMetadataType>): void {
|
2016-07-28 07:54:49 -04:00
|
|
|
throw unimplemented();
|
|
|
|
}
|
2016-08-10 21:21:28 -04:00
|
|
|
overrideDirective(directive: Type<any>, overrides: MetadataOverride<DirectiveMetadataType>):
|
|
|
|
void {
|
2016-07-28 07:54:49 -04:00
|
|
|
throw unimplemented();
|
|
|
|
}
|
2016-08-10 21:21:28 -04:00
|
|
|
overrideComponent(component: Type<any>, overrides: MetadataOverride<ComponentMetadataType>):
|
|
|
|
void {
|
2016-07-28 07:54:49 -04:00
|
|
|
throw unimplemented();
|
|
|
|
}
|
2016-08-10 21:21:28 -04:00
|
|
|
overridePipe(directive: Type<any>, overrides: MetadataOverride<PipeMetadataType>): void {
|
2016-07-28 07:54:49 -04:00
|
|
|
throw unimplemented();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A factory for creating a Compiler
|
|
|
|
*
|
|
|
|
* @experimental
|
|
|
|
*/
|
|
|
|
export abstract class TestingCompilerFactory {
|
|
|
|
abstract createTestingCompiler(options?: CompilerOptions[]): TestingCompiler;
|
|
|
|
}
|