ALKMaps.Format.Text

Read Text format.  Create a new instance with the ALKMaps.Format.Text constructor.  This reads text which is formatted like CSV text, using tabs as the separator by default.  It provides parsing of data originally used in the MapViewerService, described on the wiki.  This Format is used by the ALKMaps.Layer.Text class.

Inherits from

Summary
ALKMaps.Format.TextRead Text format.
Properties
defaultStyledefaultStyle allows one to control the default styling of the features.
extractStylesset to true to extract styles from the TSV files, using information from the image or icon, iconSize and iconOffset fields.
Constructor
ALKMaps.Format.TextCreate a new parser for TSV Text.
Functions
readReturn a list of features from a Tab Seperated Values text string.

Properties

defaultStyle

defaultStyle allows one to control the default styling of the features.  It should be a symbolizer hash.  By default, this is set to match the Layer.Text behavior, which is to use the default ALKMaps Icon.

extractStyles

set to true to extract styles from the TSV files, using information from the image or icon, iconSize and iconOffset fields.  This will result in features with a symbolizer (style) property set, using the default symbolizer specified in defaultStyle.  Set to false if you wish to use a styleMap or ALKMaps.Style options to style your layer instead.

Constructor

ALKMaps.Format.Text

Create a new parser for TSV Text.

Parameters

options{Object} An optional object whose properties will be set on this instance.

Functions

read

read: function(text)

Return a list of features from a Tab Seperated Values text string.

Parameters

text{String}

Returns

Array({ALKMaps.Feature.Vector})

read: function(text)
Return a list of features from a Tab Seperated Values text string.
Create a new parser for TSV Text.
This layer creates markers given data in a text file.
Base class for format reading/writing a variety of formats.
defaultStyle allows one to control the default styling of the features.
Vector features use the ALKMaps.Geometry classes as geometry description.
Close