UNPKG

square-connect

Version:

JavaScript client library for the Square Connect v2 API

77 lines (61 loc) 2.61 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 CatalogQuerySet model module. * @module model/CatalogQuerySet */ /** * Constructs a new <code>CatalogQuerySet</code>. * The query filter to return the search result(s) by exact match of the specified &#x60;attribute_name&#x60; and any of the &#x60;attribute_values&#x60;. * @alias module:model/CatalogQuerySet * @class * @param attributeName {String} The name of the attribute to be searched. Matching of the attribute name is exact. * @param attributeValues {Array.<String>} The desired values of the search attribute. Matching of the attribute values is exact and case insensitive. A maximum of 250 values may be searched in a request. */ var exports = function(attributeName, attributeValues) { var _this = this; _this['attribute_name'] = attributeName; _this['attribute_values'] = attributeValues; }; /** * Constructs a <code>CatalogQuerySet</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/CatalogQuerySet} obj Optional instance to populate. * @return {module:model/CatalogQuerySet} The populated <code>CatalogQuerySet</code> instance. */ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); if (data.hasOwnProperty('attribute_name')) { obj['attribute_name'] = ApiClient.convertToType(data['attribute_name'], 'String'); } if (data.hasOwnProperty('attribute_values')) { obj['attribute_values'] = ApiClient.convertToType(data['attribute_values'], ['String']); } } return obj; } /** * The name of the attribute to be searched. Matching of the attribute name is exact. * @member {String} attribute_name */ exports.prototype['attribute_name'] = undefined; /** * The desired values of the search attribute. Matching of the attribute values is exact and case insensitive. A maximum of 250 values may be searched in a request. * @member {Array.<String>} attribute_values */ exports.prototype['attribute_values'] = undefined; module.exports = exports;