schemaAttributes

class SchemaAttributes(schemaParser)

A description of a HED schema’s attributes.

Constructor.

Arguments:
SchemaAttributes.SchemaAttributes

Constructor.

SchemaAttributes.hasUnitClasses

type: boolean

Whether the schema has unit classes.

SchemaAttributes.hasUnitModifiers

type: boolean

Whether the schema has unit modifiers.

SchemaAttributes.tagAttributes

type: Object.<string, Object.<string, (boolean|string|Array.<string>)>>

The mapping from attributes to tags to values.

SchemaAttributes.tagUnitClasses

type: Object.<string, Array.<string>>

The mapping from tags to their unit classes.

SchemaAttributes.tags

type: Array.<string>

The list of all (formatted) tags.

SchemaAttributes.unitAttributes

type: Object.<string, Object.<string, (boolean|string|Array.<string>)>>

The mapping from units to their attributes.

SchemaAttributes.unitClassAttributes

type: Object.<string, Object.<string, (boolean|string|Array.<string>)>>

The mapping from unit classes to their attributes.

SchemaAttributes.unitClasses

type: Object.<string, Array.<string>>

The mapping from unit classes to their units.

SchemaAttributes.unitModifiers

type: Object.<string, Array.<string>>

The mapping from unit modifier types to unit modifiers.

SchemaAttributes.tagHasAttribute(tag, tagAttribute)

Determine if a HED tag has a particular attribute in this schema.

Arguments:
  • tag (string) – The HED tag to check.

  • tagAttribute (string) – The attribute to check for.

Returns:

boolean|null – Whether this tag has this attribute, or null if the attribute doesn’t exist.