import ts from 'ohos-typescript'; import { Decorator } from '../base/Decorator'; import { ArkError } from '../common/ArkError'; import { ArkMetadata, ArkMetadataKind, ArkMetadataType } from './ArkMetadata'; export declare enum ModifierType { PRIVATE = 1, PROTECTED = 2, PUBLIC = 4, EXPORT = 8, STATIC = 16, ABSTRACT = 32, ASYNC = 64, CONST = 128, ACCESSOR = 256, DEFAULT = 512, IN = 1024, READONLY = 2048, OUT = 4096, OVERRIDE = 8192, DECLARE = 16384, TYPE = 32768, LAZY = 65536, AUTO = 1048576, EXTERN = 2097152, FRIEND = 4194304, VIRTUAL = 8388608, PURE_VIRTUAL = 16777216, INLINE = 33554432, MUTABLE = 67108864, EXPLICIT = 134217728, CONSTEXPR = 268435456, VOLATILE = 536870912, NOEXCEPT = 1073741824 } export declare const MODIFIER_TYPE_MASK = 65535; /** * Shift amount for class-specific tag encoding. * BaseModelTag uses bits 0-15 for shared properties. * Class-specific properties start at bit 16. */ export declare const CLASS_SPECIFIC_TAG_SHIFT = 16; /** * BaseModelTag is a bitmask enumeration defining shared property tags. * These tags use bits 0-15 and are shared across multiple ArkBaseModel subclasses. * * Bit allocation: * - Bits 0-15: Shared property area (defined in BaseModelTag) * - Bits 16+: Class-specific property area (defined in each subclass file) * * Design principle: * - Shared semantic tags are defined here to avoid conflicts * - Class-specific tags are defined in respective subclass files using bit 16+ */ export declare enum BaseModelTag { /** * Bit 0: Indicates whether a method is generated by the analyzer. * Used in ArkMethod to mark compiler-generated methods like default constructors. */ GENERATED = 1, /** * Bit 1: Indicates whether a method has an asterisk token (generator function). * Used in ArkMethod for async generator methods. */ ASTERISK_TOKEN = 2, /** * Bit 2: Indicates whether a method or field has a question token (optional modifier). * Shared semantic in ArkMethod and ArkField to mark optional members. */ QUESTION_TOKEN = 4, /** * Bit 3: Indicates whether a field has an exclamation token (definite assignment assertion). * Used in ArkField to mark fields with '!' modifier. */ EXCLAMATION_TOKEN = 8 } export declare function modifierKind2Enum(kind: ts.SyntaxKind): ModifierType; export declare function modifierKind2CxxEnum(kind: string): ModifierType; export declare function modifiers2stringArray(modifiers: number): string[]; export declare abstract class ArkBaseModel { protected modifiers?: number; protected tags?: number; protected decorators?: Set; protected metadata?: ArkMetadata; getMetadata(kind: ArkMetadataKind): ArkMetadataType | undefined; setMetadata(kind: ArkMetadataKind, value: ArkMetadataType): void; getModifiers(): number; setModifiers(modifiers: number): void; addModifier(modifier: ModifierType | number): void; removeModifier(modifier: ModifierType): void; isStatic(): boolean; isProtected(): boolean; isPrivate(): boolean; isPublic(): boolean; isReadonly(): boolean; isAbstract(): boolean; isExport(): boolean; isDefault(): boolean; isPureVirtual(): boolean; /** @deprecated Since version 1.0.91. Use {@link isExport} instead. */ isExported(): boolean; isDeclare(): boolean; containsModifier(modifierType: ModifierType): boolean; getTags(): number; setTags(tags: number): void; addTag(tag: BaseModelTag | number): void; removeTag(tag: BaseModelTag): void; containsTag(tag: BaseModelTag | number): boolean; protected setTagValue(mask: number, shift: number, value: number): void; protected getTagValue(mask: number, shift: number): number; getDecorators(): Decorator[]; setDecorators(decorators: Set): void; addDecorator(decorator: Decorator): void; removeDecorator(kind: string): void; hasBuilderDecorator(): boolean; getStateDecorators(): Decorator[]; hasBuilderParamDecorator(): boolean; hasEntryDecorator(): boolean; hasComponentDecorator(): boolean; hasDecorator(kind: string | Set): boolean; protected validateFields(fields: string[]): ArkError; abstract validate(): ArkError; } //# sourceMappingURL=ArkBaseModel.d.ts.map