ContextSymbols
Creates a proxy which provides us access to the symbols defined in given context (could be lazy loaded module or the root module).
Constructor Summary
Public Constructor | ||
public |
constructor(program: ts.Program, resourceResolver: ResourceResolver) Creates an instance of ContextSymbols. |
Method Summary
Public Methods | ||
public |
getAnalyzedModules(): * |
|
public |
getContextSummary(): CompileNgModuleSummary | undefined Returns the summary of this context. |
|
public |
getDirectiveFromNode(declaration: ts.ClassDeclaration, fileName: string): * Returns directive based on |
|
public |
Returns all the directives available in the context. |
|
public |
getModules(): ModuleSymbol[] Returns the metadata associated to this module. |
|
public |
getPipes(): PipeSymbol[] Returns all the pipes available in this module. |
|
public |
updateProgram(program: ts.Program) Updates the program which has impact over the loaded symbols. |
Public Constructors
public constructor(program: ts.Program, resourceResolver: ResourceResolver) source
Creates an instance of ContextSymbols.
Params:
Name | Type | Attribute | Description |
program | ts.Program | ||
resourceResolver | ResourceResolver |
Public Methods
public getContextSummary(): CompileNgModuleSummary | undefined source
Returns the summary of this context.
Return:
CompileNgModuleSummary | undefined |
public getDirectiveFromNode(declaration: ts.ClassDeclaration, fileName: string): * source
Returns directive based on ClassDeclaration
node and a filename.
Params:
Name | Type | Attribute | Description |
declaration | ts.ClassDeclaration | ||
fileName | string |
Return:
* |
public getDirectives(): DirectiveSymbol[] source
Returns all the directives available in the context.
public getModules(): ModuleSymbol[] source
Returns the metadata associated to this module.
Return:
ModuleSymbol[] |
public updateProgram(program: ts.Program) source
Updates the program which has impact over the loaded symbols.
In case the udpate
method is called with program different from
the current one, all the internal caches will be cleared.
Params:
Name | Type | Attribute | Description |
program | ts.Program |