Class for reading and writing encoded polylines. Create a new instance with the OpenLayers.Format.EncodedPolyline constructor.
| OpenLayers. | Class for reading and writing encoded polylines. | 
| Properties | |
| geometryType | {String} Geometry type to output. | 
| Constructor | |
| OpenLayers. | Create a new parser for encoded polylines | 
| Functions | |
| read | Deserialize an encoded polyline string and return a vector feature. | 
| decode | Deserialize an encoded string and return an array of n-dimensional points. | 
| write | Serialize a feature or array of features into a WKT string. | 
| encode | Serialize an array of n-dimensional points and return an encoded string | 
| encodeDeltas | Encode a list of n-dimensional points and return an encoded string | 
| decodeDeltas | Decode a list of n-dimensional points from an encoded string | 
| encodeFloats | Encode a list of floating point numbers and return an encoded string | 
| decodeFloats | Decode a list of floating point numbers from an encoded string | 
| encodeSignedIntegers | Encode a list of signed integers and return an encoded string | 
| decodeSignedIntegers | Decode a list of signed integers from an encoded string | 
| encodeUnsignedIntegers | Encode a list of unsigned integers and return an encoded string | 
| decodeUnsignedIntegers | Decode a list of unsigned integers from an encoded string | 
| encodeFloat | Encode one single floating point number and return an encoded string | 
| decodeFloat | Decode one single floating point number from an encoded string | 
| encodeSignedInteger | Encode one single signed integer and return an encoded string | 
| decodeSignedInteger | Decode one single signed integer from an encoded string | 
| encodeUnsignedInteger | Encode one single unsigned integer and return an encoded string | 
| decodeUnsignedInteger | Decode one single unsigned integer from an encoded string | 
Create a new parser for encoded polylines
| options | {Object} An optional object whose properties will be set on this instance | 
{OpenLayers.Format.EncodedPolyline} A new encoded polylines parser.
read: function( encoded ) 
Deserialize an encoded polyline string and return a vector feature.
| encoded | {String} An encoded polyline string | 
{OpenLayers.Feature.Vector} A vector feature with a linestring.
decode: function( encoded, dims, opt_factor ) 
Deserialize an encoded string and return an array of n-dimensional points.
| encoded | {String} An encoded string | 
| dims | {int} The dimension of the points that are returned | 
{Array(Array(int))} An array containing n-dimensional arrays of coordinates.
encodeDeltas: function( numbers, dimension, opt_factor ) 
Encode a list of n-dimensional points and return an encoded string
Attention: This function will modify the passed array!
| numbers | {Array.<number>} A list of n-dimensional points. | 
| dimension | {number} The dimension of the points in the list. | 
| opt_factor | {number=} The factor by which the numbers will be multiplied. The remaining decimal places will get rounded away. | 
{string} The encoded string.
decodeDeltas: function( encoded, dimension, opt_factor ) 
Decode a list of n-dimensional points from an encoded string
| encoded | {string} An encoded string. | 
| dimension | {number} The dimension of the points in the encoded string. | 
| opt_factor | {number=} The factor by which the resulting numbers will be divided. | 
{Array.<number>} A list of n-dimensional points.
encodeFloats: function( numbers, opt_factor ) 
Encode a list of floating point numbers and return an encoded string
Attention: This function will modify the passed array!
| numbers | {Array.<number>} A list of floating point numbers. | 
| opt_factor | {number=} The factor by which the numbers will be multiplied. The remaining decimal places will get rounded away. | 
{string} The encoded string.
encodeFloat: function( num, opt_factor ) 
Encode one single floating point number and return an encoded string
| num | {number} Floating point number that should be encoded. | 
| opt_factor | {number=} The factor by which num will be multiplied. The remaining decimal places will get rounded away. | 
{string} The encoded string.
Deserialize an encoded polyline string and return a vector feature.
read: function( encoded ) 
Deserialize an encoded string and return an array of n-dimensional points.
decode: function( encoded, dims, opt_factor ) 
Serialize a feature or array of features into a WKT string.
write: function( features ) 
Serialize an array of n-dimensional points and return an encoded string
encode: function ( points, dims, opt_factor ) 
Encode a list of n-dimensional points and return an encoded string
encodeDeltas: function( numbers, dimension, opt_factor ) 
Decode a list of n-dimensional points from an encoded string
decodeDeltas: function( encoded, dimension, opt_factor ) 
Encode a list of floating point numbers and return an encoded string
encodeFloats: function( numbers, opt_factor ) 
Decode a list of floating point numbers from an encoded string
decodeFloats: function( encoded, opt_factor ) 
Encode a list of signed integers and return an encoded string
encodeSignedIntegers: function( numbers ) 
Decode a list of signed integers from an encoded string
decodeSignedIntegers: function( encoded ) 
Encode a list of unsigned integers and return an encoded string
encodeUnsignedIntegers: function( numbers ) 
Decode a list of unsigned integers from an encoded string
decodeUnsignedIntegers: function( encoded ) 
Encode one single floating point number and return an encoded string
encodeFloat: function( num, opt_factor ) 
Decode one single floating point number from an encoded string
decodeFloat: function( encoded, opt_factor ) 
Encode one single signed integer and return an encoded string
encodeSignedInteger: function( num ) 
Decode one single signed integer from an encoded string
decodeSignedInteger: function( encoded ) 
Encode one single unsigned integer and return an encoded string
encodeUnsignedInteger: function( num ) 
Decode one single unsigned integer from an encoded string
decodeUnsignedInteger: function( encoded )