winccoa-manager
    Preparing search index...

    Interface Variant

    Represents a variant value that can be used as type-safe handover of values between OA and JavaScript. Use the factory methods to create instances of the variant and the getter methods to retrieve the value.

    interface Variant {
        get value(): unknown;
        get variableType(): VariableType;
        equals(other: Vrpc.Variant): boolean;
        getAlertTime(): WinccoaAlertTime;
        getAlertTimeArray(): WinccoaAlertTime[];
        getBit32(): number;
        getBit32Array(): number[];
        getBit64(asBigInt?: boolean): number | bigint;
        getBit64(manager?: WinccoaManager): number | bigint;
        getBit64Array(asBigInt?: boolean): number[] | bigint[];
        getBit64Array(manager?: WinccoaManager): number[] | bigint[];
        getBlob(): Buffer;
        getBlobArray(): Buffer<ArrayBufferLike>[];
        getBool(): boolean;
        getBooleanArray(): boolean[];
        getByte(): number;
        getByteArray(): number[];
        getDouble(): number;
        getDoubleArray(): number[];
        getDpIdentifier(): string;
        getDpIdentifierArray(): string[];
        getInt(): number;
        getIntArray(): number[];
        getLangString(): Vrpc.LangString;
        getLangStringArray(): Vrpc.LangString[];
        getLong(asBigInt?: boolean): number | bigint;
        getLong(manager?: WinccoaManager): number | bigint;
        getLongArray(asBigInt?: boolean): number[] | bigint[];
        getLongArray(manager?: WinccoaManager): number[] | bigint[];
        getMapping(): Vrpc.Mapping;
        getMappingArray(): Vrpc.Mapping[];
        getString(): string;
        getStringArray(): string[];
        getTime(timeFormat?: WinccoaTimeFormat): WinccoaTime;
        getTime(manager?: WinccoaManager): WinccoaTime;
        getTimeArray(timeFormat?: WinccoaTimeFormat): WinccoaTime[];
        getTimeArray(manager?: WinccoaManager): WinccoaTime[];
        getUInt(): number;
        getUIntArray(): number[];
        getULong(asBigInt?: boolean): number | bigint;
        getULong(manager?: WinccoaManager): number | bigint;
        getULongArray(asBigInt?: boolean): number[] | bigint[];
        getULongArray(manager?: WinccoaManager): number[] | bigint[];
        getValue(manager?: WinccoaManager): unknown;
        isAlertTime(): boolean;
        isAlertTimeArray(): boolean;
        isBit32(): boolean;
        isBit32Array(): boolean;
        isBit64(): boolean;
        isBit64Array(): boolean;
        isBlob(): boolean;
        isBlobArray(): boolean;
        isBool(): boolean;
        isBooleanArray(): boolean;
        isByte(): boolean;
        isByteArray(): boolean;
        isDouble(): boolean;
        isDoubleArray(): boolean;
        isDpIdentifier(): boolean;
        isDpIdentifierArray(): boolean;
        isInt(): boolean;
        isIntArray(): boolean;
        isLangString(): boolean;
        isLangStringArray(): boolean;
        isLong(): boolean;
        isLongArray(): boolean;
        isMapping(): boolean;
        isMappingArray(): boolean;
        isNull(): boolean;
        isString(): boolean;
        isStringArray(): boolean;
        isTime(): boolean;
        isTimeArray(): boolean;
        isUInt(): boolean;
        isUIntArray(): boolean;
        isULong(): boolean;
        isULongArray(): boolean;
        isUndefined(): boolean;
        isVariableType(variableType: VariableType): boolean;
        toString(): string;
    }
    Index

    Accessors

    • get value(): unknown

      The value of the variant, in default JavaScript representation.

      Returns unknown

      The value of the variant.

    Methods

    • Checks if the variant is equal to another variant.

      Parameters

      Returns boolean

      True if the variants are equal, otherwise false.

    • Gets the array of alert time values of the variant.

      Returns WinccoaAlertTime[]

      The array of alert time values of the variant.

    • Gets the 32-bit bitfield value of the variant.

      Returns number

      The 32-bit bitfield value of the variant.

    • Gets the array of 32-bit bitfield values of the variant.

      Returns number[]

      The array of 32-bit bitfield values of the variant.

    • Gets the 64-bit bitfield value of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the value as a BigInt.

      Returns number | bigint

      The 64-bit bitfield value of the variant.

    • Gets the 64-bit value value of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number | bigint

      The long value of the variant.

    • Gets the array of 64-bit bitfield values of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the values as BigInts.

      Returns number[] | bigint[]

      The array of 64-bit bitfield values of the variant.

    • Gets the array of 64-bit bitfield values of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number[] | bigint[]

      The array of 64-bit bitfield values of the variant.

    • Gets the blob value of the variant.

      Returns Buffer

      The blob value of the variant.

    • Gets the array of blob values of the variant.

      Returns Buffer<ArrayBufferLike>[]

      The array of blob values of the variant.

    • Gets the boolean value of the variant.

      Returns boolean

      The boolean value of the variant.

    • Gets the array of boolean values of the variant.

      Returns boolean[]

      The array of boolean values of the variant.

    • Gets the byte value of the variant.

      Returns number

      The byte value of the variant.

    • Gets the array of byte values of the variant.

      Returns number[]

      The array of byte values of the variant.

    • Gets the double value of the variant.

      Returns number

      The double value of the variant.

    • Gets the array of double values of the variant.

      Returns number[]

      The array of double values of the variant.

    • Gets the data point identifier value of the variant.

      Returns string

      The data point identifier value of the variant.

    • Gets the array of data point identifier values of the variant.

      Returns string[]

      The array of data point identifier values of the variant.

    • Gets the integer value of the variant.

      Returns number

      The integer value of the variant.

    • Gets the array of integer values of the variant.

      Returns number[]

      The array of integer values of the variant.

    • Gets the array of LangString values of the variant.

      Returns Vrpc.LangString[]

      The array of LangString values of the variant.

    • Gets the long value of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the value as a BigInt.

      Returns number | bigint

      The long value of the variant.

    • Gets the long value of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number | bigint

      The long value of the variant.

    • Gets the array of long values of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the values as BigInts.

      Returns number[] | bigint[]

      The array of long values of the variant.

    • Gets the array of long values of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number[] | bigint[]

      The array of long values of the variant.

    • Gets the mapping value of the variant.

      Returns Vrpc.Mapping

      The mapping value of the variant.

    • Gets the array of mapping values of the variant.

      Returns Vrpc.Mapping[]

      The array of mapping values of the variant.

    • Gets the string value of the variant.

      Returns string

      The string value of the variant.

    • Gets the array of string values of the variant.

      Returns string[]

      The array of string values of the variant.

    • Gets the unsigned integer value of the variant.

      Returns number

      The unsigned integer value of the variant.

    • Gets the array of unsigned integer values of the variant.

      Returns number[]

      The array of unsigned integer values of the variant.

    • Gets the unsigned long value of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the value as a BigInt.

      Returns number | bigint

      The unsigned long value of the variant.

    • Gets the unsinged long value of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number | bigint

      The long value of the variant.

    • Gets the array of unsigned long values of the variant.

      Parameters

      • OptionalasBigInt: boolean

        Whether to return the values as BigInts.

      Returns number[] | bigint[]

      The array of unsigned long values of the variant.

    • Gets the array of unsigned long values of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns number[] | bigint[]

      The array of unsigned long values of the variant.

    • Gets the value of the variant.

      Parameters

      • Optionalmanager: WinccoaManager

        The manager to get formating options from.

      Returns unknown

      The value of the variant.

    • Checks if the variant is an alert time.

      Returns boolean

      True if the variant is an alert time, false otherwise.

    • Checks if the variant is an array of alert time values.

      Returns boolean

      True if the variant is an array of alert time values, false otherwise.

    • Checks if the variant is a 32-bit bitfield.

      Returns boolean

      True if the variant is a 32-bit bitfield, false otherwise.

    • Checks if the variant is an array of 32-bit bitfields.

      Returns boolean

      True if the variant is an array of 32-bit bitfields, false otherwise.

    • Gets the 64-bit bitfield value of the variant.

      Returns boolean

      The 64-bit bitfield value of the variant.

    • Checks if the variant is an array of 64-bit bitfields.

      Returns boolean

      True if the variant is an array of 64-bit bitfields, false otherwise.

    • Checks if the variant is a blob.

      Returns boolean

      True if the variant is a blob, false otherwise.

    • Checks if the variant is an array of blobs.

      Returns boolean

      True if the variant is an array of blobs, false otherwise.

    • Checks if the variant is a bool.

      Returns boolean

      True if the variant is a bool, false otherwise.

    • Checks if the variant is an array of booleans.

      Returns boolean

      True if the variant is an array of booleans, false otherwise.

    • Checks if the variant is a byte.

      Returns boolean

      True if the variant is a byte, false otherwise.

    • Checks if the variant is an array of bytes.

      Returns boolean

      True if the variant is an array of bytes, false otherwise.

    • Checks if the variant is a double.

      Returns boolean

      True if the variant is a double, false otherwise.

    • Checks if the variant is an array of doubles.

      Returns boolean

      True if the variant is an array of doubles, false otherwise.

    • Checks if the variant is a data point identifier.

      Returns boolean

      True if the variant is a data point identifier, false otherwise.

    • Checks if the variant is an array of data point identifiers.

      Returns boolean

      True if the variant is an array of data point identifiers, false otherwise.

    • Checks if the variant is an integer.

      Returns boolean

      True if the variant is an integer, false otherwise.

    • Checks if the variant is an array of integers.

      Returns boolean

      True if the variant is an array of integers, false otherwise.

    • Checks if the variant is a LangString.

      Returns boolean

      True if the variant is a LangString, false otherwise.

    • Checks if the variant is an array of LangString values.

      Returns boolean

      True if the variant is an array of LangString values, false otherwise.

    • Checks if the variant is a long.

      Returns boolean

      True if the variant is a long, false otherwise.

    • Checks if the variant is an array of longs.

      Returns boolean

      True if the variant is an array of longs, false otherwise.

    • Checks if the variant is a mapping.

      Returns boolean

      True if the variant is a mapping, false otherwise.

    • Checks if the variant is an array of mappings.

      Returns boolean

      True if the variant is an array of mappings, false otherwise.

    • Checks if the variant is null.

      Returns boolean

      True if the variant is null, false otherwise.

    • Checks if the variant is a string.

      Returns boolean

      True if the variant is a string, false otherwise.

    • Checks if the variant is an array of strings.

      Returns boolean

      True if the variant is an array of strings, false otherwise.

    • Checks if the variant is a time.

      Returns boolean

      True if the variant is a time, false otherwise.

    • Checks if the variant is an array of time values.

      Returns boolean

      True if the variant is an array of time values, false otherwise.

    • Checks if the variant is an unsigned integer.

      Returns boolean

      True if the variant is an unsigned integer, false otherwise.

    • Checks if the variant is an array of unsigned integers.

      Returns boolean

      True if the variant is an array of unsigned integers, false otherwise.

    • Checks if the variant is an unsigned long.

      Returns boolean

      True if the variant is an unsigned long, false otherwise.

    • Checks if the variant is an array of unsigned longs.

      Returns boolean

      True if the variant is an array of unsigned longs, false otherwise.

    • Checks if the variant is undefined.

      Returns boolean

      True if the variant is undefined, false otherwise.

    • Checks if the variant is of the specified variable type.

      Parameters

      Returns boolean

      True if the variant is of the specified variable type, false otherwise.

    • Converts the variant to a string.

      Returns string

      The string representation of the variant.