PropsOfConverter
Hierarchy
- PropsOfConverter
Implements
- TypeConverter
- TypeConverter
Index
Methods
Methods
convert
▸ convert(reflectedType
: tsruntimeTypes.ReflectedType, converter
: Converter): Collection
Converts reflected utility type to properties of class.
Parameters:
Name | Type | Description |
---|---|---|
reflectedType | tsruntimeTypes.ReflectedType | Reflected type. |
converter | Converter | Instance of converter. |
Returns: Collection
Returns converted class properties as instance of Collection
pattern.
isConvertible
▸ isConvertible(reflectedType
: tsruntimeTypes.ReflectedType, converter
: Converter): boolean
Evaluates if provided reflected type uses utility type $PropsOf
.
Parameters:
Name | Type | Description |
---|---|---|
reflectedType | tsruntimeTypes.ReflectedType | Reflected type. |
converter | Converter | Instance of converter. |
Returns: boolean
Returns true
if reflected type is a utility type $PropsOf
and has valid class type payload, else false
.
reflect
▸ reflect(reflectedType
: tsruntimeTypes.ReflectedType, converter
: Converter): Record‹keyof any, any›
Reflects utility type to properties of class.
Parameters:
Name | Type | Description |
---|---|---|
reflectedType | tsruntimeTypes.ReflectedType | Reflected type. |
converter | Converter | Instance of converter. |
Returns: Record‹keyof any, any›
Returns reflected class properties as instance of an Object
pattern.