Class SpatialGraphHelper
This class contains helper function to interact or transform the common
ISpatialEdge object.
Inheritance
System.Object
SpatialGraphHelper
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Assembly: Mars.Components.dll
Syntax
public static class SpatialGraphHelper
Methods
|
Improve this Doc
View Source
DeserializeGraph(Stream, out IDictionary<Int32, SpatialNode>, out IDictionary<Int32, SpatialEdge>, out BoundingBox, out KeyContainer, out SpatialGraphOptions)
Declaration
public static SpatialGraph DeserializeGraph(Stream stream, out IDictionary<int, SpatialNode> nodes, out IDictionary<int, SpatialEdge> edges, out BoundingBox boundingBox, out KeyContainer keyContainer, out SpatialGraphOptions sgeOptions)
Parameters
Returns
Exceptions
Type |
Condition |
System.ArgumentNullException |
|
|
Improve this Doc
View Source
ToFeature(ISpatialEdge)
This class contains helper function to interact or transform the common
ISpatialEdge object.
Declaration
public static IFeature ToFeature(this ISpatialEdge edge)
Parameters
Returns
Type |
Description |
NetTopologySuite.Features.IFeature |
|
|
Improve this Doc
View Source
ToFeature(ISpatialNode)
This class contains helper function to interact or transform the common
ISpatialEdge object.
Declaration
public static IFeature ToFeature(this ISpatialNode node)
Parameters
Returns
Type |
Description |
NetTopologySuite.Features.IFeature |
|
|
Improve this Doc
View Source
ToFeature(Route)
Transforms the specified route
into a NetTopologySuite.Features.IFeature object .
Declaration
public static IFeature ToFeature(this Route route)
Parameters
Type |
Name |
Description |
Route |
route |
The route to transform. |
Returns
Type |
Description |
NetTopologySuite.Features.IFeature |
Returns a new NetTopologySuite.Features.IFeature object containing the
path as geometry and the properties as attribute table entries.
|
Exceptions
Type |
Condition |
System.ArgumentNullException |
Route is null. |
|
Improve this Doc
View Source
ToGeoJson(ISpatialGraphEnvironment)
Transforms the specified environment
in to valid GeoJson string.
Declaration
public static string ToGeoJson(this ISpatialGraphEnvironment environment)
Parameters
Returns
Type |
Description |
System.String |
Returns the GeoJson string |
Exceptions
Type |
Condition |
System.ArgumentNullException |
Environment is null. |
|
Improve this Doc
View Source
ToGeoJson(Route)
Transforms the specified route
in to valid GeoJson string.
Declaration
public static string ToGeoJson(this Route route)
Parameters
Type |
Name |
Description |
Route |
route |
The route to transform. |
Returns
Type |
Description |
System.String |
Returns the GeoJson string |
Exceptions
Type |
Condition |
System.ArgumentNullException |
Route is null. |
|
Improve this Doc
View Source
ToGeometry(ISpatialEdge)
Transforms the passed edge
into an NetTopologySuite.Geometries.Geometry
object as point, a line string or line ring.
Declaration
public static Geometry ToGeometry(this ISpatialEdge edge)
Parameters
Type |
Name |
Description |
ISpatialEdge |
edge |
The edge to transform |
Returns
Type |
Description |
NetTopologySuite.Geometries.Geometry |
Returns a new NetTopologySuite.Geometries.Geometry object which can be a NetTopologySuite.Geometries.Point,
NetTopologySuite.Geometries.LineString or a NetTopologySuite.Geometries.LinearRing.
|
Exceptions
Type |
Condition |
System.ArgumentException |
The edge doesn't have any coordinates. |