[I] ProjectedProgram
Extends
Properties
Property | Modifier | Type | Description | Inherited from |
---|---|---|---|---|
checker | public | Checker | - | Program .checker |
compilerOptions | public | CompilerOptions | - | Program .compilerOptions |
diagnostics | readonly | readonly Diagnostic [] | - | Program .diagnostics |
emitters | public | EmitterRef [] | - | Program .emitters |
host | public | CompilerHost | - | Program .host |
jsSourceFiles | public | Map <string , JsSourceFileNode > | - | Program .jsSourceFiles |
literalTypes | public | Map <string | number | boolean , LiteralType > | - | Program .literalTypes |
mainFile? | public | TypeSpecScriptNode | - | Program .mainFile |
projector | public | Projector | - | - |
projectRoot | readonly | string | Project root. If a tsconfig was found/specified this is the directory for the tsconfig.json. Otherwise directory where the entrypoint is located. | Program .projectRoot |
sourceFiles | public | Map <string , TypeSpecScriptNode > | All source files in the program, keyed by their file path. | Program .sourceFiles |
stateMaps | public | Map <symbol , StateMap > | - | Program .stateMaps |
stateSets | public | Map <symbol , StateSet > | - | Program .stateSets |
tracer | public | Tracer | - | Program .tracer |
Methods
getGlobalNamespaceType()
Returns
Inherited from
Program
.getGlobalNamespaceType
getOption()
Parameters
Parameter | Type |
---|---|
key | string |
Returns
undefined
| string
Inherited from
getSourceFileLocationContext()
Return location context of the given source file.
Parameters
Parameter | Type |
---|---|
sourceFile | SourceFile |
Returns
Inherited from
Program
.getSourceFileLocationContext
hasError()
Returns
boolean
Inherited from
loadTypeSpecScript()
Parameters
Parameter | Type |
---|---|
typespecScript | SourceFile |
Returns
Promise
<TypeSpecScriptNode
>
Inherited from
onValidate()
Parameters
Parameter | Type |
---|---|
cb | (program ) => void | Promise <void > |
LibraryMetadata | LibraryMetadata |
Returns
void
Inherited from
reportDiagnostic()
Parameters
Parameter | Type |
---|---|
diagnostic | Diagnostic |
Returns
void
Inherited from
reportDiagnostics()
Parameters
Parameter | Type |
---|---|
diagnostics | readonly Diagnostic [] |
Returns
void
Inherited from
reportDuplicateSymbols()
Parameters
Parameter | Type |
---|---|
symbols | undefined | SymbolTable |
Returns
void
Inherited from
Program
.reportDuplicateSymbols
resolveTypeReference()
Parameters
Parameter | Type |
---|---|
reference | string |
Returns
[undefined
| Type
, readonly Diagnostic
[]]
Inherited from
stateMap()
Parameters
Parameter | Type |
---|---|
key | symbol |
Returns
Map
<Type
, any
>
Inherited from
stateSet()
Parameters
Parameter | Type |
---|---|
key | symbol |
Returns
Set
<Type
>
Inherited from
trace()
Parameters
Parameter | Type |
---|---|
area | string |
message | string |
Returns
void