HED JavaScript Library
    Preparing search index...

    Class SchemaUnitClass

    SchemaUnitClass class

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    _name: string

    The name of this schema entry.

    _units: Map<string, SchemaUnit>

    The units for this unit class.

    booleanAttributeNames: Set<string>

    The set of boolean attribute names this schema entry has.

    booleanAttributes: Set<SchemaAttribute>

    The set of boolean attributes this schema entry has.

    valueAttributeNames: Map<string, any>

    The collection of value attribute names this schema entry has.

    valueAttributes: Map<SchemaAttribute, any>

    The collection of value attributes this schema entry has.

    Accessors

    • get name(): string

      The name of this schema entry.

      Returns string

    Methods

    • Protected

      Memoize a property.

      Type Parameters

      • T

      Parameters

      • propertyName: string

        The property name.

      • valueComputer: () => T

        A function to compute the property's value.

      Returns T

      The computed value.

    • Extracts the Unit class and remainder

      Parameters

      • value: any

      Returns any[]

      [SchemaUnit, string, string] containing unit class, unit string, and value string

    • Retrieve the value of a value attribute (by name) on this schema entry.

      Parameters

      • attributeName: string

        The attribute whose value should be returned.

      • alwaysReturnArray: boolean = false

        Whether to return a singleton array instead of a scalar value.

      Returns any

      The value of the attribute.