@getopenpay/client
Version:
OpenPay API TypeScript SDK
58 lines (57 loc) • 2.26 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* OpenPay API
* super charge your subscription management.
*
* The version of the OpenAPI document: 1.2.1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.instanceOfAllConditionsTrueBranchInput = instanceOfAllConditionsTrueBranchInput;
exports.AllConditionsTrueBranchInputFromJSON = AllConditionsTrueBranchInputFromJSON;
exports.AllConditionsTrueBranchInputFromJSONTyped = AllConditionsTrueBranchInputFromJSONTyped;
exports.AllConditionsTrueBranchInputToJSON = AllConditionsTrueBranchInputToJSON;
exports.AllConditionsTrueBranchInputToJSONTyped = AllConditionsTrueBranchInputToJSONTyped;
const Condition_1 = require("./Condition");
/**
* Check if a given object implements the AllConditionsTrueBranchInput interface.
*/
function instanceOfAllConditionsTrueBranchInput(value) {
if (!('ifAllConditionsTrue' in value) || value['ifAllConditionsTrue'] === undefined)
return false;
if (!('thenGoToNodeId' in value) || value['thenGoToNodeId'] === undefined)
return false;
return true;
}
function AllConditionsTrueBranchInputFromJSON(json) {
return AllConditionsTrueBranchInputFromJSONTyped(json, false);
}
function AllConditionsTrueBranchInputFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'branchName': json['branch_name'] == null ? undefined : json['branch_name'],
'ifAllConditionsTrue': (json['if_all_conditions_true'].map(Condition_1.ConditionFromJSON)),
'thenGoToNodeId': json['then_go_to_node_id'],
};
}
function AllConditionsTrueBranchInputToJSON(json) {
return AllConditionsTrueBranchInputToJSONTyped(json, false);
}
function AllConditionsTrueBranchInputToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'branch_name': value['branchName'],
'if_all_conditions_true': (value['ifAllConditionsTrue'].map(Condition_1.ConditionToJSON)),
'then_go_to_node_id': value['thenGoToNodeId'],
};
}