2015-02-18 19:26:06 -08:00
|
|
|
/*global define*/
|
|
|
|
|
|
|
|
define(
|
2015-02-23 10:48:44 -08:00
|
|
|
['./TextProxy', './AccessorMutator'],
|
|
|
|
function (TextProxy, AccessorMutator) {
|
2015-02-18 19:26:06 -08:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
/**
|
2015-02-23 10:48:44 -08:00
|
|
|
* Selection proxy for telemetry elements in a fixed position view.
|
2015-02-18 19:26:06 -08:00
|
|
|
*
|
2015-02-23 10:48:44 -08:00
|
|
|
* Note that arguments here are meant to match those expected
|
|
|
|
* by `Array.prototype.map`
|
|
|
|
*
|
|
|
|
* @constructor
|
|
|
|
* @param element the fixed position element, as stored in its
|
|
|
|
* configuration
|
|
|
|
* @param index the element's index within its array
|
|
|
|
* @param {Array} elements the full array of elements
|
2015-02-18 19:26:06 -08:00
|
|
|
*/
|
|
|
|
function TelemetryProxy(element, index, elements) {
|
2015-02-23 10:48:44 -08:00
|
|
|
var proxy = new TextProxy(element, index, elements);
|
2015-02-18 19:26:06 -08:00
|
|
|
|
2015-02-23 10:48:44 -08:00
|
|
|
// Expose the domain object identifier
|
2015-02-18 19:26:06 -08:00
|
|
|
proxy.id = element.id;
|
|
|
|
|
|
|
|
return proxy;
|
|
|
|
}
|
|
|
|
|
|
|
|
return TelemetryProxy;
|
|
|
|
}
|
|
|
|
);
|