Sha256: 77817985f9eb7068b920006df3cefe13acf291b47bdadfd3992f3f8f89e66a92

Contents?: true

Size: 1.59 KB

Versions: 3

Compression:

Stored size: 1.59 KB

Contents

/*global define*/
define([
        '../Core/defaultValue'
    ], function(
        defaultValue) {
    "use strict";

    /**
     * Provides methods for working with a string defined in CZML.
     *
     * @exports CzmlString
     *
     * @see DynamicProperty
     * @see CzmlCartesian2
     * @see CzmlCartesian3
     * @see CzmlPosition
     * @see CzmlColor
     * @see CzmlHorizontalOrigin
     * @see CzmlLabelStyle
     * @see CzmlNumber
     * @see CzmlString
     * @see CzmlUnitCartesian3
     * @see CzmlUnitQuaternion
     * @see CzmlUnitSpherical
     * @see CzmlVerticalOrigin
     */
    var CzmlString = {
        /**
         * Returns the packed string representation contained within the provided CZML interval
         * or undefined if the interval does not contain string data.
         *
         * @param {Object} czmlInterval The CZML interval to unwrap.
         */
        unwrapInterval : function(czmlInterval) {
            return defaultValue(czmlInterval.string, czmlInterval);
        },

        /**
         * Since CZML strings can not be sampled, this method always returns false.
         */
        isSampled : function() {
            return false;
        },

        /**
         * Returns the string value contained within the unwrappedInterval.  For strings
         * this is the unwrappedInterval itself.
         *
         * @param {Object} unwrappedInterval The result of CzmlString.unwrapInterval.
         * @returns The string value.
         */
        getValue : function(unwrappedInterval) {
            return unwrappedInterval;
        }
    };

    return CzmlString;
});

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cesium-0.18.0 app/assets/javascripts/DynamicScene/CzmlString.js
cesium-0.17.0 app/assets/javascripts/DynamicScene/CzmlString.js
cesium-0.16.0 app/assets/javascripts/DynamicScene/CzmlString.js