Source: inventory/ModifierGroup.js

/**
 * Autogenerated by Avro
 * 
 * DO NOT EDIT DIRECTLY
 */

var base_Reference = require("../base/Reference");
var inventory_Modifier = require("../inventory/Modifier");

/**
* @constructor
* @memberof inventory
*/
var ModifierGroup = function() {
  this._class_ = ModifierGroup;
  this.id = undefined;
  this.name = undefined;
  this.alternateName = undefined;
  this.minRequired = undefined;
  this.maxAllowed = undefined;
  this.showByDefault = true;
  this.modifiers = undefined;
  this.modifierIds = undefined;
  this.items = undefined;
  this.sortOrder = undefined;
};


/**
* Set the field value
* Unique identifier
*
* @memberof inventory.ModifierGroup
* @param {String} id 
*/
ModifierGroup.prototype.setId = function(id) {
  this.id = id;
};

/**
* Get the field value
* Unique identifier
* @memberof inventory.ModifierGroup
* @return {String} 
*/
ModifierGroup.prototype.getId = function() {
  return this.id;
};

/**
* Set the field value
* Name of the modifier group
*
* @memberof inventory.ModifierGroup
* @param {String} name 
*/
ModifierGroup.prototype.setName = function(name) {
  this.name = name;
};

/**
* Get the field value
* Name of the modifier group
* @memberof inventory.ModifierGroup
* @return {String} 
*/
ModifierGroup.prototype.getName = function() {
  return this.name;
};

/**
* Set the field value
* @memberof inventory.ModifierGroup
* @param {String} alternateName 
*/
ModifierGroup.prototype.setAlternateName = function(alternateName) {
  this.alternateName = alternateName;
};

/**
* Get the field value
* @memberof inventory.ModifierGroup
* @return {String} 
*/
ModifierGroup.prototype.getAlternateName = function() {
  return this.alternateName;
};

/**
* Set the field value
* The minimum amount of modifiers from this group that must be applied to associated lineItems when using Register
*
* @memberof inventory.ModifierGroup
* @param {Number} minRequired must be an integer
*/
ModifierGroup.prototype.setMinRequired = function(minRequired) {
  this.minRequired = minRequired;
};

/**
* Get the field value
* The minimum amount of modifiers from this group that must be applied to associated lineItems when using Register
* @memberof inventory.ModifierGroup
* @return {Number} must be an integer
*/
ModifierGroup.prototype.getMinRequired = function() {
  return this.minRequired;
};

/**
* Set the field value
* The maximum amount of modifiers from this group that can be applied to associated lineItems when using Register
*
* @memberof inventory.ModifierGroup
* @param {Number} maxAllowed must be an integer
*/
ModifierGroup.prototype.setMaxAllowed = function(maxAllowed) {
  this.maxAllowed = maxAllowed;
};

/**
* Get the field value
* The maximum amount of modifiers from this group that can be applied to associated lineItems when using Register
* @memberof inventory.ModifierGroup
* @return {Number} must be an integer
*/
ModifierGroup.prototype.getMaxAllowed = function() {
  return this.maxAllowed;
};

/**
* Set the field value
* Whether employees will be automatically prompted to add modifiers from this category when using Register
*
* @memberof inventory.ModifierGroup
* @param {Boolean} showByDefault 
*/
ModifierGroup.prototype.setShowByDefault = function(showByDefault) {
  this.showByDefault = showByDefault;
};

/**
* Get the field value
* Whether employees will be automatically prompted to add modifiers from this category when using Register
* @memberof inventory.ModifierGroup
* @return {Boolean} 
*/
ModifierGroup.prototype.getShowByDefault = function() {
  return this.showByDefault;
};

/**
* Set the field value
* @memberof inventory.ModifierGroup
* @param {Array.<inventory.Modifier>} modifiers An array of 
*/
ModifierGroup.prototype.setModifiers = function(modifiers) {
  this.modifiers = modifiers;
};

/**
* Get the field value
* @memberof inventory.ModifierGroup
* @return {Array.<inventory.Modifier>} An array of 
*/
ModifierGroup.prototype.getModifiers = function() {
  return this.modifiers;
};

/**
* Set the field value
* An ordered, comma-separated list of modifier ids in this group. (READ ONLY)
*
* @memberof inventory.ModifierGroup
* @param {String} modifierIds 
*/
ModifierGroup.prototype.setModifierIds = function(modifierIds) {
  this.modifierIds = modifierIds;
};

/**
* Get the field value
* An ordered, comma-separated list of modifier ids in this group. (READ ONLY)
* @memberof inventory.ModifierGroup
* @return {String} 
*/
ModifierGroup.prototype.getModifierIds = function() {
  return this.modifierIds;
};

/**
* Set the field value
* @memberof inventory.ModifierGroup
* @param {Array.<base.Reference>} items An array of 
*/
ModifierGroup.prototype.setItems = function(items) {
  this.items = items;
};

/**
* Get the field value
* @memberof inventory.ModifierGroup
* @return {Array.<base.Reference>} An array of 
*/
ModifierGroup.prototype.getItems = function() {
  return this.items;
};

/**
* Set the field value
* The ordinal value used to determine where in an ordered list this modifier group should appear relative to others.
*
* @memberof inventory.ModifierGroup
* @param {Number} sortOrder must be an integer
*/
ModifierGroup.prototype.setSortOrder = function(sortOrder) {
  this.sortOrder = sortOrder;
};

/**
* Get the field value
* The ordinal value used to determine where in an ordered list this modifier group should appear relative to others.
* @memberof inventory.ModifierGroup
* @return {Number} must be an integer
*/
ModifierGroup.prototype.getSortOrder = function() {
  return this.sortOrder;
};

/**
* @memberof inventory.ModifierGroup
* @private
*/
ModifierGroup.prototype.getMetaInfo = function(fieldName) {
  var curclass = this._class_;
  do {
    var fieldMetaInfo = curclass._meta_.fields[fieldName];
    if(fieldMetaInfo) {
      return fieldMetaInfo;
    }
    if(curclass._meta_._superMeta_) {
      curclass = curclass._meta_._superMeta_._class_;
    } else {
      curclass = null;
    }
  } while(curclass);
  return null;
};

ModifierGroup.prototype.toString = function() {
  return JSON.stringify(this);
};

ModifierGroup._meta_ =  {fields:  {}};
ModifierGroup._meta_._class_ =  ModifierGroup;
ModifierGroup._meta_.fields["id"] = {};
ModifierGroup._meta_.fields["id"].type = String;
ModifierGroup._meta_.fields["name"] = {};
ModifierGroup._meta_.fields["name"].type = String;
ModifierGroup._meta_.fields["alternateName"] = {};
ModifierGroup._meta_.fields["alternateName"].type = String;
ModifierGroup._meta_.fields["minRequired"] = {};
ModifierGroup._meta_.fields["minRequired"].type = Number;
ModifierGroup._meta_.fields["maxAllowed"] = {};
ModifierGroup._meta_.fields["maxAllowed"].type = Number;
ModifierGroup._meta_.fields["showByDefault"] = {};
ModifierGroup._meta_.fields["showByDefault"].type = Boolean;
ModifierGroup._meta_.fields["modifiers"] = {};
ModifierGroup._meta_.fields["modifiers"].type = Array;
ModifierGroup._meta_.fields["modifiers"].elementType = inventory_Modifier;
ModifierGroup._meta_.fields["modifierIds"] = {};
ModifierGroup._meta_.fields["modifierIds"].type = String;
ModifierGroup._meta_.fields["items"] = {};
ModifierGroup._meta_.fields["items"].type = Array;
ModifierGroup._meta_.fields["items"].elementType = base_Reference;
ModifierGroup._meta_.fields["sortOrder"] = {};
ModifierGroup._meta_.fields["sortOrder"].type = Number;

//
// Expose the module.
//
if ('undefined' !== typeof module) {
module.exports = ModifierGroup;
}