chore(facade): add enum index lookup support
This commit is contained in:

committed by
Alex Eagle

parent
8e3e45097a
commit
b691da26af
@ -195,6 +195,10 @@ export function deserializeEnum(val, values: Map<number, any>): any {
|
||||
return val;
|
||||
}
|
||||
|
||||
export function resolveEnumToken(enumValue, val): string {
|
||||
return enumValue[val];
|
||||
}
|
||||
|
||||
export class StringWrapper {
|
||||
static fromCharCode(code: number): string { return String.fromCharCode(code); }
|
||||
|
||||
@ -468,4 +472,4 @@ export function isPrimitive(obj: any): boolean {
|
||||
|
||||
export function hasConstructor(value: Object, type: Type): boolean {
|
||||
return value.constructor === type;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user