import UuidWrapper from "../../uuidWrapper"; import { ByteVector } from "../../byteVector"; /** * Indicates the type of data stored in a {@link ContentDescriptor} or {@link MetadataDescriptor} object. */ export declare enum DataType { /** * The descriptor contains Unicode (UTF-16LE) text. */ Unicode = 0, /** * The descriptor contains binary data. */ Bytes = 1, /** * The descriptor contains a boolean value. */ Bool = 2, /** * The descriptor contains a 4-byte DWORD value. */ DWord = 3, /** * The descriptor contains an 8-byte QWORD value. */ QWord = 4, /** * The descriptor contains a 2-byte WORD value. */ Word = 5, /** * The descriptor contains a 16-byte GUID value. */ Guid = 6 } /** * Type shortcut for all the types a descriptor can contain */ export declare type DescriptorValue = bigint | boolean | ByteVector | number | string | UuidWrapper; /** * Abstract class that forms the basis of extended content descriptors and metadata library records. */ export declare abstract class DescriptorBase { private readonly _name; private readonly _type; private readonly _boolValue; private readonly _byteValue; private readonly _dWordValue; private readonly _guidValue; private readonly _qWordValue; private readonly _stringValue; private readonly _wordValue; protected constructor(name: string, type: DataType, value: DescriptorValue); /** * Gets the name of the current instance. */ get name(): string; /** * Gets the type of data contained in the current instance. */ get type(): DataType; /** * Gets the boolean value of the current instance. * @returns * Boolean value of the current instance is returned if {@link type} is * {@link DataType.Bool}. `undefined` is returned otherwise. */ get boolValue(): boolean; /** * Gets the binary contents of the current instance. * @returns * Byte contents of the current instance, if {@link type} is * {@link DataType.Bytes}. `undefined` is returned otherwise. */ get byteValue(): ByteVector; /** * Gets the guid contents of the current instance. * @returns * GUID contents of the current instance, if {@link type} is * {@link DataType.Guid}. `undefined` is returned otherwise. */ get guidValue(): UuidWrapper; /** * Gets the string contents of the current instance. * @returns * String contents of the current instance if {@link type} is * {@link DataType.Unicode}. `undefined` is returned otherwise. */ get stringValue(): string; /** * Gets the 32-bit double word contents of the current instance. * @returns * Double word contents of the current instance, if {@link type} is * {@link DataType.DWord}. `undefined` is returned otherwise. */ get uintValue(): number; /** * Gets the 64-bit quad word contents of the current instance. * @returns * Quad word contents of the current instance, if {@link type} is * {@link DataType.QWord}. `undefined` is returned otherwise. */ get ulongValue(): bigint; /** * Gets the 16-bit word contents of the current instance. * @returns * Word contents of the current instance, if {@link type} is * {@link DataType.Word}. `undefined` is returned otherwise. */ get ushortValue(): number; abstract render(): ByteVector; /** @inheritDoc */ toString(): string; }