EnumTypeConverter Class

Enum Type Converter.

Extends

Methods

Name Description
constructor(): EnumTypeConverter    
convertPropertyToString(propertyDescription: PropertyDescription, value?: Primitives.Enum): string | Promise<string> Converts a value associated with a property description to a string  
sortCompare(a: Primitives.Enum, b: Primitives.Enum, ignoreCase?: boolean): number Sort function for two primitive values  

Inherited methods

Name Inherited from Description
convertFromString(_value: string): undefined | ConvertedPrimitives.Value | Promise<Value undefined> TypeConverter
convertFromStringToPropertyValue(value: string, propertyRecord?: PropertyRecord): Promise<PropertyValue> TypeConverter Converts a string with a property record to a property value
convertFromStringWithOptions(value: string, _options?: [key: string]: any): undefined | ConvertedPrimitives.Value | Promise<Value undefined> TypeConverter
convertToString(value?: Primitives.Value): string | Promise<string> TypeConverter Converts a primitive value to a string
convertToStringWithOptions(value?: Primitives.Value, _options?: [key: string]: any): string | Promise<string> TypeConverter Default implementation just calls convertToString with no options
isEqualTo(valueA: Primitives.Value, valueB: Primitives.Value): boolean TypeConverter Determines if two primitive values are equal
isNotEqualTo(valueA: Primitives.Value, valueB: Primitives.Value): boolean TypeConverter Determines if two primitive values are not equal
isNotNull(value: Primitives.Value): boolean TypeConverter Determines if a primitive value is not null or not undefined
isNull(value: Primitives.Value): boolean TypeConverter Determines if a primitive value is null or undefined

Inherited properties

Name Type Inherited from Description
isBooleanType Accessor ReadOnly boolean TypeConverter Determines if the converter is for a boolean type
isLessGreaterType Accessor ReadOnly boolean TypeConverter Determines if the converter is for a numeric type
isNullableType Accessor ReadOnly boolean TypeConverter Determines if the converter is for a nullable type
isStringType Accessor ReadOnly boolean TypeConverter Determines if the converter is for a string type

Defined in

Last Updated: 13 November, 2024