Cesium for Unity 1.23.0
Loading...
Searching...
No Matches
CesiumForUnity.CesiumGeoJsonObject Class Reference

Represents an object in a GeoJSON document. More...

Public Member Functions

partial CesiumGeoJsonObjectType GetObjectType ()
 Gets the type of this GeoJSON object.
 
partial bool IsValid ()
 Checks whether this GeoJSON object is valid.
 
partial CesiumGeoJsonFeature GetObjectAsFeature ()
 Gets this object as a CesiumGeoJsonFeature, if it is a Feature.
 
partial CesiumGeoJsonFeature[] GetObjectAsFeatureCollection ()
 Gets the features in this FeatureCollection.
 
partial double3 GetObjectAsPoint ()
 Gets this object as a Point geometry.
 
partial double3[] GetObjectAsMultiPoint ()
 Gets this object as a MultiPoint geometry.
 
partial CesiumGeoJsonLineString GetObjectAsLineString ()
 Gets this object as a LineString geometry.
 
partial CesiumGeoJsonLineString[] GetObjectAsMultiLineString ()
 Gets this object as a MultiLineString geometry.
 
partial CesiumGeoJsonPolygon GetObjectAsPolygon ()
 Gets this object as a Polygon geometry.
 
partial CesiumGeoJsonPolygon[] GetObjectAsMultiPolygon ()
 Gets this object as a MultiPolygon geometry.
 
partial CesiumGeoJsonObject[] GetObjectAsGeometryCollection ()
 Gets this object as a GeometryCollection.
 
partial bool HasStyle ()
 Checks whether this GeoJSON object has a style.
 
partial CesiumVectorStyle GetStyle ()
 Gets the style of this GeoJSON object.
 
partial void SetStyle (CesiumVectorStyle style)
 Sets the style of this GeoJSON object.
 
partial void ClearStyle ()
 Clears any style set on this GeoJSON object.
 

Detailed Description

Represents an object in a GeoJSON document.

A GeoJSON object can be a geometry (Point, LineString, Polygon, etc.), a Feature (geometry with properties), or a collection of other objects. Use GetObjectAsFeature to access Feature-specific data, or GetObjectAsFeatureCollection to access the features in a FeatureCollection.

Definition at line 20 of file CesiumGeoJsonObject.cs.

Member Function Documentation

◆ ClearStyle()

partial void CesiumForUnity.CesiumGeoJsonObject.ClearStyle ( )

Clears any style set on this GeoJSON object.

After calling this method, the object will inherit its style from its parent, or use the default style if no parent has a style.

◆ GetObjectAsFeature()

partial CesiumGeoJsonFeature CesiumForUnity.CesiumGeoJsonObject.GetObjectAsFeature ( )

Gets this object as a CesiumGeoJsonFeature, if it is a Feature.

Returns
A CesiumGeoJsonFeature if this object is a Feature; null otherwise.

◆ GetObjectAsFeatureCollection()

partial CesiumGeoJsonFeature[] CesiumForUnity.CesiumGeoJsonObject.GetObjectAsFeatureCollection ( )

Gets the features in this FeatureCollection.

Returns
An array of CesiumGeoJsonFeature if this object is a FeatureCollection; null otherwise.

◆ GetObjectAsGeometryCollection()

partial CesiumGeoJsonObject[] CesiumForUnity.CesiumGeoJsonObject.GetObjectAsGeometryCollection ( )

Gets this object as a GeometryCollection.

Returns
An array of CesiumGeoJsonObject if this object is a GeometryCollection; null otherwise.

◆ GetObjectAsLineString()

partial CesiumGeoJsonLineString CesiumForUnity.CesiumGeoJsonObject.GetObjectAsLineString ( )

Gets this object as a LineString geometry.

Returns
A CesiumGeoJsonLineString if this object is a LineString; null otherwise.

◆ GetObjectAsMultiLineString()

partial CesiumGeoJsonLineString[] CesiumForUnity.CesiumGeoJsonObject.GetObjectAsMultiLineString ( )

Gets this object as a MultiLineString geometry.

Returns
An array of CesiumGeoJsonLineString if this object is a MultiLineString; null otherwise.

◆ GetObjectAsMultiPoint()

partial double3[] CesiumForUnity.CesiumGeoJsonObject.GetObjectAsMultiPoint ( )

Gets this object as a MultiPoint geometry.

Returns
An array of double3 with the points' LLH coordinates, or null if this object is not a MultiPoint.

◆ GetObjectAsMultiPolygon()

partial CesiumGeoJsonPolygon[] CesiumForUnity.CesiumGeoJsonObject.GetObjectAsMultiPolygon ( )

Gets this object as a MultiPolygon geometry.

Returns
An array of CesiumGeoJsonPolygon if this object is a MultiPolygon; null otherwise.

◆ GetObjectAsPoint()

partial double3 CesiumForUnity.CesiumGeoJsonObject.GetObjectAsPoint ( )

Gets this object as a Point geometry.

Returns
A double3 with the point's LLH coordinates, or a zero vector if this object is not a Point.

◆ GetObjectAsPolygon()

partial CesiumGeoJsonPolygon CesiumForUnity.CesiumGeoJsonObject.GetObjectAsPolygon ( )

Gets this object as a Polygon geometry.

Returns
A CesiumGeoJsonPolygon if this object is a Polygon; null otherwise.

◆ GetObjectType()

partial CesiumGeoJsonObjectType CesiumForUnity.CesiumGeoJsonObject.GetObjectType ( )

Gets the type of this GeoJSON object.

◆ GetStyle()

partial CesiumVectorStyle CesiumForUnity.CesiumGeoJsonObject.GetStyle ( )

Gets the style of this GeoJSON object.

Returns
The style, or the default style if no style is set.

◆ HasStyle()

partial bool CesiumForUnity.CesiumGeoJsonObject.HasStyle ( )

Checks whether this GeoJSON object has a style.

Returns
True if this object has a style; false otherwise.

◆ IsValid()

partial bool CesiumForUnity.CesiumGeoJsonObject.IsValid ( )

Checks whether this GeoJSON object is valid.

Returns
True if this object is valid; false otherwise.

◆ SetStyle()

partial void CesiumForUnity.CesiumGeoJsonObject.SetStyle ( CesiumVectorStyle style)

Sets the style of this GeoJSON object.

Parameters
styleThe style to set.

The documentation for this class was generated from the following file: