wallee
Version:
TypeScript/JavaScript client for wallee
33 lines (32 loc) • 1.28 kB
JavaScript
/**
* Check if a given object implements the ExpressCheckoutShippingOption interface.
*/
export function instanceOfExpressCheckoutShippingOption(value) {
return true;
}
export function ExpressCheckoutShippingOptionFromJSON(json) {
return ExpressCheckoutShippingOptionFromJSONTyped(json, false);
}
export function ExpressCheckoutShippingOptionFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'amount': json['amount'] == null ? undefined : json['amount'],
'description': json['description'] == null ? undefined : json['description'],
'currency': json['currency'] == null ? undefined : json['currency'],
'id': json['id'] == null ? undefined : json['id'],
'label': json['label'] == null ? undefined : json['label'],
'taxAmount': json['taxAmount'] == null ? undefined : json['taxAmount'],
'selected': json['selected'] == null ? undefined : json['selected'],
};
}
export function ExpressCheckoutShippingOptionToJSON(json) {
return ExpressCheckoutShippingOptionToJSONTyped(json, false);
}
export function ExpressCheckoutShippingOptionToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {};
}