import { Expression, NewExpression } from './expressions'; import { MemberType } from './member-type'; import { PropertySpec } from './property'; import { IScope, IScopeLink } from './scope'; import { ThingSymbol } from './symbol'; import { Type } from './type'; import { DeclarationKind, TypeDeclaration, TypeSpec } from './type-declaration'; import { Initializer, InitializerSpec, MethodSpec } from './type-member'; export interface ClassSpec extends TypeSpec { properties?: PropertySpec[]; methods?: MethodSpec[]; abstract?: boolean; extends?: Type; implements?: Type[]; } export declare class ClassType extends MemberType implements IScope { scope: IScope; readonly spec: ClassSpec; readonly kind = DeclarationKind.Class; private readonly classScope; readonly nestedDeclarations: TypeDeclaration[]; /** * List the modifiers of the interface */ get modifiers(): Array; private _initializer?; private registeredInParentScope; constructor(scope: IScope, spec: ClassSpec); get initializer(): Initializer | undefined; get extends(): Type | undefined; get implements(): Type[]; addInitializer(spec: InitializerSpec): Initializer; newInstance(...args: Expression[]): NewExpression; /** * Update some of the fields of the class spec, except fields that are immutable or managed elsewhere. * * Members are managed via specific method calls. */ update, 'properties' | 'methods' | 'name'>>(updates: A): void; get typeMap(): ReadonlyMap; qualifyName(name: string): string; registerType(type: TypeDeclaration): void; tryFindType(fqn: string): TypeDeclaration | undefined; linkScope(scope: IScope, theImport: IScopeLink): void; linkSymbol(sym: ThingSymbol, exp: Expression): void; symbolToExpression(symbol: ThingSymbol): Expression | undefined; }