Interface AstReflection

Service used for generic access to the structure of the AST. This service is shared between all involved languages, so it operates on the superset of types of these languages.

interface AstReflection {
    getAllSubTypes(type: string): string[];
    getAllTypes(): string[];
    getReferenceType(refInfo: ReferenceInfo): string;
    getTypeMetaData(type: string): TypeMetaData;
    isInstance(node: unknown, type: string): boolean;
    isSubtype(subtype: string, supertype: string): boolean;
}

Implemented by

Methods