IShapeReaderInfo

Description

interface Tinman.Terrain.Shapes.IShapeReaderInfo

Extended by

IShapeReader

Base interface for classes that provide read-only information for shape readers.

This interface may be used to pass around IShapeReader objects with read-only access.

Public / Methods

Peek​Georef


public method PeekGeoref → ()

returns → CoordinateSystem

The CoordinateSystem object returned by IShapeInfo.Georef of the IShape object that will be returned by the next call to IShapeReader.ReadShape or null iff the reader has finished.

Peeks at the geo-reference of the shape that is going to be read next.

IOException

If an I/O error has occurred.

Peek​Id


public method PeekId → ()

returns → int32

The identifier or -1 iff the reader has finished.

Peeks at the unique ordinal number identifier of the next shape feature in the shape data.

The ordinal number can be used to identify individual shape features that are present in the shape data, before they get classified as compatible shape data and are merged in one IShape object.

IOException

If an I/O error has occurred.

Peek​Metadata


public method PeekMetadata → ()

returns → IJsonValue

The JsonValue object returned by IShapeInfo.Metadata of the IShape object that will be returned by the next call to IShapeReader.ReadShape or null iff the reader has finished.

Peeks at the metadata of the shape that is going to be read next.

Modified metadata may be passed to a subsequent call to IShapeReader.ReadShape.

IOException

If an I/O error has occurred.

Peek​Type


public method PeekType → ()

returns → ShapeType

The ShapeType value returned by IShapeInfo.Type of the IShape object that will be returned by the next call to IShapeReader.ReadShape or ShapeType.Implicit if the reader has finished (see remarks).

Peeks at the type of the shape that is going to be read next.

After returning ShapeType.Mesh from the PeekType method, an implementation may choose to build a shape of type ShapeType.Polygon instead. This way, the triangulation step may be omitted if the shape data uses polygon contours to describe mesh data. Use IShapeOps.Convert to get a ShapeType.Mesh shape, which will perform triangulation if necessary.

IOException

If an I/O error has occurred.

Peek​Values


public method PeekValues → ()

returns → ShapeValue

The ShapeValue value returned by IShapeInfo.ValueMask of the IShape object that will be returned by the next call to IShapeReader.ReadShape or ShapeValue.None if the reader has finished.

Peeks at the set of custom values of the shape that is going to be read next.

IOException

If an I/O error has occurred.

Public / Attributes

Flags


public attribute Flags → (get)

value : ReadShapeFlags

The shape read flags.

The shape read flags of this shape reader.

Has​Finished


public attribute HasFinished → (get)

value : bool

true if all shapes have been read, false if not.

Has the shape reader finished, i.e. all shape data has been read?

If this property returns true, subsequent calls to IShapeReader.ReadShape and IShapeReader.SkipShape will always return null resp. false, because there is no more shape data to process.
If this property returns false, subsequent calls to IShapeReader.ReadShape and IShapeReader.SkipShape may still return null resp. false, because the remaining shape data does not contain any more shape geometry that would yield a IShape object.

IOException

If an I/O error has occurred.