Provides static utility methods for validating and creating strings representing names.
These methods should be used when creating names for elements in the data manager, like a data table or a data column.

2.0

Hierarchy (view full)

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 null | T1

  • 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 MaxLength(): number
  • Gets the maximum length of a name string.

    Returns number

    2.0

  • Tests if two unnormalized strings represent the same name.

    Parameters

    • s1: string | String

      The first string.

    • s2: string | String

      The second string.

    Returns boolean

    True if the strings are equivalent.

    2.0

  • Normalizes a name string by trimming at both ends and converting to Unicode normal form C.

    Parameters

    • name: string | String

      The string to be normalized.

    Returns string

    The normalized string.

    2.0

  • Makes a suggested name string unique within a collection by appending a suffix. Truncates the suggested name if it is too long for a name string, and normalizes the name.

    Parameters

    Returns string

    A unique name string.

    2.0

  • Checks if a string can be used as a valid name.

    Parameters

    • nameCandidate: string | String

      The string.

    Returns boolean

    True if the string is not empty or too long.

    2.0

  • Checks if an input string can be used as a name.

    Parameters

    Returns boolean

    True if okay.

    2.0

  • Validates the name of a custom Spotfire.Dxp.Data.DataProperty.

    Parameters

    • propertyName: string | String

      Name of the property.

    Returns void

    2.0