Enumeration Class @preview
A Typescript class representation of an ECEnumeration.
Extends
Methods
| Name | Description | |
|---|---|---|
| fromJSON(enumerationProps: EnumerationProps): Promise<void> | ||
| fromJSONSync(enumerationProps: EnumerationProps): void | ||
| getEnumerator(value: string): undefined | Enumerator<string> | Gets an enumerator that matches the value provided. | |
| getEnumerator(value: number): undefined | Enumerator<number> | ||
| getEnumeratorByName(name: string): undefined | AnyEnumerator | Gets an enumerator that matches the name provided. | |
| toJSON(standalone: boolean = false, includeSchemaVersion: boolean = false): EnumerationProps | Save this Enumeration's properties to an object for serializing to JSON. | |
| isEnumeration(item?: SchemaItem): item is Enumeration Static | Type guard to check if the SchemaItem is of type Enumeration. |
Inherited methods
| Name | Inherited from | Description |
|---|---|---|
| equalByKey(thisSchemaItem: SchemaItem, thatSchemaItemOrKey?: SchemaItemKey | SchemaItem): boolean Static Inherited | SchemaItem | Indicates if the two SchemaItem objects are equal by comparing their respective key properties. |
| parseFullName(fullName: string): [string, string] Static Inherited | SchemaItem | Parses the given full name, {schemaName}.{schemaItemName} or {schemaName}:{schemaItemName}, into two separate strings. |
Properties
| Name | Type | Description | |
|---|---|---|---|
| enumerators Accessor ReadOnly | ReadonlyArray<AnyEnumerator> | ||
| isInt Accessor ReadOnly | boolean | ||
| isStrict Accessor ReadOnly | boolean | ||
| isString Accessor ReadOnly | boolean | ||
| schemaItemType Readonly | SchemaItemType | Get the type of item represented by this instance | |
| type Accessor ReadOnly | undefined | Integer | String |
Inherited properties
| Name | Type | Inherited from | Description |
|---|---|---|---|
| description Accessor Inherited ReadOnly | undefined | string | SchemaItem | |
| fullName Accessor Inherited ReadOnly | string | SchemaItem | |
| key Accessor Inherited ReadOnly | SchemaItemKey | SchemaItem | |
| label Accessor Inherited ReadOnly | undefined | string | SchemaItem | |
| name Accessor Inherited ReadOnly | string | SchemaItem | |
| schema Readonly Inherited | Schema | SchemaItem |
Defined in
Last Updated: 28 October, 2025
Found something wrong, missing, or unclear on this page? Raise an issue in our repo.