[Time API] Provided 'AddFormat' method for registering new formats

This commit is contained in:
Henry
2017-04-30 23:21:13 -07:00
parent 31897ec520
commit 0793442518
8 changed files with 63 additions and 106 deletions

View File

@ -316,6 +316,17 @@ define([
return this.formatMapCache.get(metadata);
};
/**
* Register a new telemetry data formatter.
* @param {Format} format the
*/
TelemetryAPI.prototype.addFormat = function (format) {
this.MCT.legacyExtension('formats', {
key: format.key,
implementation: function () { return format }
});
};
/**
* Get a limit evaluator for this domain object.
* Limit Evaluators help you evaluate limit and alarm status of individual telemetry datums for display purposes without having to interact directly with the Limit API.