Class

ShumateVectorReaderIter

since: 1.2

Description [src]

final class Shumate.VectorReaderIter : GObject.Object
{
  /* No available fields */
}

Reads the layers and features of a vector tile.

To create a new ShumateVectorReaderIter, use shumate_vector_reader_iterate().

A vector tile consists of named layers, which contain features. Each feature has an ID, a geometry, and a set of key/value tags. The meanings of the IDs and tags depends on the data source that the tile came from. The OpenMapTiles schema is a common schema for vector tiles.

To read all layers in a tile, use shumate_vector_reader_iter_get_layer_count() and shumate_vector_reader_iter_read_layer(). If you know the name of the layer you want, you can also use shumate_vector_reader_iter_read_layer_by_name(). Once the iterator is reading a layer, you can call shumate_vector_reader_iter_next_feature() in a loop to read all the features in the layer.

A ShumateVectorReaderIter is not thread-safe, but iterators created from the same ShumateVectorReader can be used in different threads.

See the Mapbox Vector Tile specification for more information about the vector tile format.

Available since: 1.2

Hierarchy

hierarchy this ShumateVectorReaderIter ancestor_0 GObject ancestor_0--this

Ancestors

Instance methods

shumate_vector_reader_iter_feature_contains_point

Determines whether the current feature contains the given point.

since: 1.2

shumate_vector_reader_iter_get_feature_geometry_type

Gets the geometry type of the current feature.

since: 1.2

shumate_vector_reader_iter_get_feature_id

Gets the ID of the current feature.

since: 1.2

shumate_vector_reader_iter_get_feature_keys

Gets the keys of the tags of the current feature.

since: 1.2

shumate_vector_reader_iter_get_feature_point

Gets the coordinates of the current feature in tile space, if the feature is a single point.

since: 1.2

shumate_vector_reader_iter_get_feature_tag

Gets the value of the tag with the given key.

since: 1.2

shumate_vector_reader_iter_get_layer_count

Gets the number of layers in the vector tile.

since: 1.2

shumate_vector_reader_iter_get_layer_extent

Gets the extent for coordinates in the current layer.

since: 1.2

shumate_vector_reader_iter_get_layer_feature_count

Gets the number of features in the current layer.

since: 1.2

shumate_vector_reader_iter_get_layer_name

Gets the name of the current layer.

since: 1.2

shumate_vector_reader_iter_get_reader

Gets the reader that the iterator is iterating over.

since: 1.2

shumate_vector_reader_iter_next_feature

Advances the iterator to the next feature in the current layer.

since: 1.2

shumate_vector_reader_iter_read_feature

Moves the iterator to the feature at the given index in the current layer.

since: 1.2

shumate_vector_reader_iter_read_layer

Sets the current layer of the reader to the layer at the given index.

since: 1.2

shumate_vector_reader_iter_read_layer_by_name

Moves the iterator to the layer with the given name, if present.

since: 1.2

Methods inherited from GObject (43)

Please see GObject for a full list of methods.

Properties

Shumate.VectorReaderIter:reader
No description available.

Signals

Signals inherited from GObject (1)
GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

Class structure

struct ShumateVectorReaderIterClass {
  GObjectClass parent_class;
  
}

No description available.

Class members
parent_class: GObjectClass

No description available.