ds/ItemSummary.js

/**
 * @fileoverview Exposed data type for use outside of DsClient.
 *               All properties should be exposed to allow use from uncompiled
 *               code.
 *
 * @author anders.rejdebrant@spark-vision.com (Anders Rejdebrant)
 */

goog.provide('spv.ds.ItemSummary');

goog.require('spv.ds.DisplayPrice');
goog.require('spv.ds.GuiPath');




/**
 * @export
 * @struct
 * @constructor
 * @param {string} item_id
 * @param {string} item_text
 * @param {spv.ds.DisplayPrice} item_price
 * @param {string} item_price_text
 * @param {string} menu_id
 * @param {string} menu_text
 * @param {Array.<spv.ds.GuiPath>} gui_paths
 * @param {Object.<string, Object>} aux_data
 */
spv.ds.ItemSummary = function(
		item_id,
		item_text,
		item_price,
		item_price_text,
		menu_id,
		menu_text,
		gui_paths,
		aux_data)
{
	/**
	 * @type {string}
	 * @nocollapse
	 */
	this.item_id = item_id;

	/**
	 * @type {string}
	 * @nocollapse
	 */
	this.item_text = item_text;

	/**
	 * Please refer to the spv.ds.DisplayPrice documentation.
	 * @type {spv.ds.DisplayPrice}
	 * @nocollapse
	 */
	this.item_price = item_price;

	/**
	 * @type {string}
	 * @deprecated Use the item_price {spv.ds.DisplayPrice} property instead.
	 * @nocollapse
	 */
	this.item_price_text = item_price_text;

	/**
	 * @type {string}
	 * @nocollapse
	 */
	this.menu_id = menu_id;

	/**
	 * @type {string}
	 * @nocollapse
	 */
	this.menu_text = menu_text;

	/**
	 * @type {Array.<spv.ds.GuiPath>}
	 * @nocollapse
	 */
	this.gui_paths = gui_paths;

	/**
	 * Untyped extra data that has to be intepreted at run time.
	 * TODO: replace this later with properly named data structures
	 *
	 * @type {Object.<string, Object>}
	 * @nocollapse
	 */
	this.aux_data = aux_data;
};