@code-to-json/core
Version:
[](https://travis-ci.org/code-to-json/code-to-json) [](https://d
35 lines • 1.26 kB
TypeScript
import { Symbol as Sym, TypeChecker } from 'typescript';
import { ProcessingQueue } from '../processing-queue';
import { SymbolRef, TypeRef } from '../processing-queue/ref';
import { HasPosition, SerializedEntity } from '../types';
import { SerializedSignature } from './signature';
export interface SerializedHeritageClause {
clauseType: string;
}
export interface SerializedSymbol extends SerializedEntity<'symbol'>, Partial<HasPosition> {
name: string;
documentation?: string;
external?: boolean;
type?: TypeRef;
members?: SymbolRef[];
exports?: SymbolRef[];
decorators?: string[];
modifiers?: string[];
globalExports?: SymbolRef[];
constructorSignatures?: SerializedSignature[];
callSignatures?: SerializedSignature[];
heritageClauses?: SerializedHeritageClause[];
jsDocTags?: Array<{
name: string;
text?: string;
}>;
}
/**
* Serialize a TS Symbol
* @param symbol Symbol to serialize
* @param checker an instance of the TS type checker
* @param ref Reference to the symbol
* @param queue Processing queue
*/
export default function serializeSymbol(symbol: Sym, checker: TypeChecker, ref: SymbolRef, queue: ProcessingQueue): SerializedSymbol;
//# sourceMappingURL=symbol.d.ts.map