UNPKG

wallee

Version:
43 lines (42 loc) 1.57 kB
/** * Check if a given object implements the PaymentTerminalCreate interface. */ export function instanceOfPaymentTerminalCreate(value) { if (!('externalId' in value) || value['externalId'] === undefined) return false; if (!('type' in value) || value['type'] === undefined) return false; return true; } export function PaymentTerminalCreateFromJSON(json) { return PaymentTerminalCreateFromJSONTyped(json, false); } export function PaymentTerminalCreateFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'name': json['name'] == null ? undefined : json['name'], 'identifier': json['identifier'] == null ? undefined : json['identifier'], 'configurationVersion': json['configurationVersion'] == null ? undefined : json['configurationVersion'], 'locationVersion': json['locationVersion'] == null ? undefined : json['locationVersion'], 'externalId': json['externalId'], 'type': json['type'], }; } export function PaymentTerminalCreateToJSON(json) { return PaymentTerminalCreateToJSONTyped(json, false); } export function PaymentTerminalCreateToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'name': value['name'], 'identifier': value['identifier'], 'configurationVersion': value['configurationVersion'], 'locationVersion': value['locationVersion'], 'externalId': value['externalId'], 'type': value['type'], }; }