wallee
Version:
TypeScript/JavaScript client for wallee
44 lines (43 loc) • 1.76 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.instanceOfBankAccount = instanceOfBankAccount;
exports.BankAccountFromJSON = BankAccountFromJSON;
exports.BankAccountFromJSONTyped = BankAccountFromJSONTyped;
exports.BankAccountToJSON = BankAccountToJSON;
exports.BankAccountToJSONTyped = BankAccountToJSONTyped;
const BankAccountState_1 = require("./BankAccountState");
/**
* Check if a given object implements the BankAccount interface.
*/
function instanceOfBankAccount(value) {
return true;
}
function BankAccountFromJSON(json) {
return BankAccountFromJSONTyped(json, false);
}
function BankAccountFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'identifier': json['identifier'] == null ? undefined : json['identifier'],
'linkedSpaceId': json['linkedSpaceId'] == null ? undefined : json['linkedSpaceId'],
'plannedPurgeDate': json['plannedPurgeDate'] == null ? undefined : (new Date(json['plannedPurgeDate'])),
'description': json['description'] == null ? undefined : json['description'],
'id': json['id'] == null ? undefined : json['id'],
'state': json['state'] == null ? undefined : (0, BankAccountState_1.BankAccountStateFromJSON)(json['state']),
'type': json['type'] == null ? undefined : json['type'],
'version': json['version'] == null ? undefined : json['version'],
};
}
function BankAccountToJSON(json) {
return BankAccountToJSONTyped(json, false);
}
function BankAccountToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'state': (0, BankAccountState_1.BankAccountStateToJSON)(value['state']),
};
}