ProjectSymbols
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 ProjectSymbols. |
Method Summary
Public Methods | ||
public |
getAnalyzedModules(): * |
|
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 |
getProviders(): ProviderSymbol[] Returns all the providers 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 ProjectSymbols.
Params:
Name | Type | Attribute | Description |
program | ts.Program | ||
resourceResolver | ResourceResolver |
Public Methods
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 getProviders(): ProviderSymbol[] source
Returns all the providers available in this module.
Return:
ProviderSymbol[] |
public updateProgram(program: ts.Program) source
Updates the program which has impact over the loaded symbols.
In case the update
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 |