UNPKG

square-connect

Version:

JavaScript client library for the Square Connect v2 API

78 lines (62 loc) 2.15 kB
/** * Square Connect API * Client library for accessing the Square Connect APIs * * OpenAPI spec version: 2.0 * Contact: developers@squareup.com * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * * Swagger Codegen version: 2.3.0-SNAPSHOT * */ var ApiClient = require('../ApiClient'); /** * The LoyaltyProgramTerminology model module. * Note: This model is in beta. * @module model/LoyaltyProgramTerminology */ /** * Constructs a new <code>LoyaltyProgramTerminology</code>. * * @alias module:model/LoyaltyProgramTerminology * @class * @param one {String} A singular unit for a point (for example, 1 point is called 1 star). * @param other {String} A plural unit for point (for example, 10 points is called 10 stars). */ var exports = function(one, other) { var _this = this; _this['one'] = one; _this['other'] = other; }; /** * Constructs a <code>LoyaltyProgramTerminology</code> from a plain JavaScript object, optionally creating a new instance. * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not. * @param {Object} data The plain JavaScript object bearing properties of interest. * @param {module:model/LoyaltyProgramTerminology} obj Optional instance to populate. * @return {module:model/LoyaltyProgramTerminology} The populated <code>LoyaltyProgramTerminology</code> instance. */ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); if (data.hasOwnProperty('one')) { obj['one'] = ApiClient.convertToType(data['one'], 'String'); } if (data.hasOwnProperty('other')) { obj['other'] = ApiClient.convertToType(data['other'], 'String'); } } return obj; } /** * A singular unit for a point (for example, 1 point is called 1 star). * @member {String} one */ exports.prototype['one'] = undefined; /** * A plural unit for point (for example, 10 points is called 10 stars). * @member {String} other */ exports.prototype['other'] = undefined; module.exports = exports;