Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose CZML helper functions. #1110

Merged
merged 2 commits into from
Sep 3, 2013
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions Source/DynamicScene/CzmlDataSource.js
Original file line number Diff line number Diff line change
Expand Up @@ -1304,6 +1304,49 @@ define([
});
};

/**
* A helper function used by custom CZML updater functions
* which creates or updates a {@link Property} from a CZML packet.
* @function
*
* @param {Function} type The constructor function for the property being processed.
* @param {Object} object The object on which the property will be added or updated.
* @param {String} propertyName The name of the property on the object.
* @param {Object} packetData The CZML packet being processed.y
* @param {TimeInterval} [interval] A constraining interval for which the data is valid.
* @param {String} [sourceUri] The originating uri of the data being processed.
* @returns {Boolean} True if a new property was created, false otherwise.
*/
CzmlDataSource.processPacketData = processPacketData;

/**
* A helper function used by custom CZML updater functions
* which creates or updates a {@link PositionProperty} from a CZML packet.
* @function
*
* @param {Object} object The object on which the property will be added or updated.
* @param {String} propertyName The name of the property on the object.
* @param {Object} packetData The CZML packet being processed.y
* @param {TimeInterval} [interval] A constraining interval for which the data is valid.
* @param {String} [sourceUri] The originating uri of the data being processed.
* @returns {Boolean} True if a new property was created, false otherwise.
*/
CzmlDataSource.processPositionPacketData = processPositionPacketData;

/**
* A helper function used by custom CZML updater functions
* which creates or updates a {@link MaterialProperty} from a CZML packet.
* @function
*
* @param {Object} object The object on which the property will be added or updated.
* @param {String} propertyName The name of the property on the object.
* @param {Object} packetData The CZML packet being processed.y
* @param {TimeInterval} [interval] A constraining interval for which the data is valid.
* @param {String} [sourceUri] The originating uri of the data being processed.
* @returns {Boolean} True if a new property was created, false otherwise.
*/
CzmlDataSource.processMaterialPacketData = processMaterialPacketData;

CzmlDataSource._processCzml = function(czml, dynamicObjectCollection, sourceUri, updaterFunctions) {
var updatedObjects = [];
var updatedObjectsHash = {};
Expand Down