Action
    Preparing search index...

    Class DataValueGeneric<T>

    Generic flyweight data value container.

    2.0

    Type Parameters

    • T

    Hierarchy (View Summary)

    Index

    Methods

    • Casts this object to the specified type. Throws error on failure.

      Type Parameters

      • T1

        The target type of the cast.

      • T2

        The type of the object to cast.

      Parameters

      Returns T1

    • Determines whether the specified object is equal to the current object.

      Parameters

      • obj: any

        The object to compare with the current object.

      Returns boolean

      true if the specified object is equal to the current object; otherwise, false.

    • Serves as the default hash function.

      Returns number

      A hash code for the current object.

    • Returns a string that represents the current object.

      Returns string

      A string that represents the current object.

    • Casts this object to the specified type. Returns null on failure.

      Type Parameters

      • T1

        The target type of the cast.

      • T2

        The type of the object to cast.

      Parameters

      Returns T1 | null

    • Determines whether the specified object instances are considered equal.

      Parameters

      • objA: any

        The first object to compare.

      • objB: any

        The second object to compare.

      Returns boolean

      true if the objects are considered equal; otherwise, false. If both objA and objB are null, the method returns true.

    Default capability

    • get DataType(): Spotfire.Dxp.Data.DataType

      Gets the data type corresponding to the runtime values that can be stored in this value container. The data type is fixed, since a data value cannot be used for values of varying types.

      Returns Spotfire.Dxp.Data.DataType

      For the time and and date data types, DataType.DateTime will be returned. That is, the subtype information is not maintained. This behaviour is not ideal and should be considered as a known issue which may be improved in a future release.

      2.0

    • get HasValidValue(): boolean

      Gets a value indicating whether this DataValue contains a valid value. If HasValidValue is false, then either IsNullValue is true or HasDataError is true, but not both. If HasValidValue is true, the IsNullValue and HasDataError are both false.

      Returns boolean

      2.0

    • get IsNullValue(): boolean

      Gets a value indicating whether this DataValue instance represents a null value, or, more precisely, an invalid value with a null data error.

      Returns boolean

      2.0

    • get ValidValue(): JsType<T>

      Gets or sets the valid value contained in this DataValue instance. A default value is returned if there is no valid value. After setting a valid value HasValidValue will be true, HasDataError and IsNullValue will be false, and DataError will return null.

      Returns JsType<T>

      2.0

    • set ValidValue(value: JsType<T>): void

      Gets or sets the runtime value contained in this DataValue instance, as a boxed value. The getter returns null for reference types and default(T) for value types, if the HasValidValue is false. After setting a valid value HasValidValue will be true, HasDataError and IsNullValue will be false, and DataError will return null.

      Parameters

      Returns void

      2.0

    • Makes this DataValue instance represent a null value. That is, an invalid value with a null data error. After the method call, HasValidValue will return false, IsNullValue will return true, and HasDataError will return false. The ValidValue property will be null or default(T).

      Returns void

      2.0