Constructors
constructor
-
Parameters
-
__namedParameters: object
Properties
Private identifiers
identifiers: object
Private includes
includes: string[]
Methods
astToJson
- astToJson(name: string, ast: IAstFile[]): ThriftFile.IJSON
-
Parameters
Returns ThriftFile.IJSON
astToType
- astToType(ast: FunctionType, file: string): ThriftFile.IFieldType
-
Parameters
-
ast: FunctionType
-
file: string
Returns ThriftFile.IFieldType
comments
- comments(input: Comment[]): object | object
-
Parameters
Returns object
|
object
constToJson
- constToJson(constant: ConstValue): any
fieldToJson
- fieldToJson(field: FieldDefinition, file: string): ThriftFile.IField
-
Parameters
-
field: FieldDefinition
-
file: string
Returns ThriftFile.IField
funcToJson
- funcToJson(func: FunctionDefinition, file: string): ThriftFile.IFunction
-
Parameters
-
func: FunctionDefinition
-
file: string
Returns ThriftFile.IFunction
ident
- ident(input: Identifier): string
-
Parameters
Returns string
identToType
- identToType(ast: Identifier, file: string): ThriftFile.IFieldType
-
Parameters
-
ast: Identifier
-
file: string
Returns ThriftFile.IFieldType
parse
- parse(filePath: string, callback: function): void
-
Parameters
-
filePath: string
-
callback: function
-
- (err: Error | null, data?: ThriftFile.IJSON): void
-
Parameters
-
err: Error | null
-
Optional data: ThriftFile.IJSON
Returns void
Returns void
parseThriftFiles
- parseThriftFiles(filePath: string, includes: string[]): Promise<IAstFile[]>
-
Parameters
-
filePath: string
-
includes: string[]
Returns Promise<IAstFile[]>
Process Thrift file
ThriftParser