DbSpatialServices.AsText Method
Gets the well known text representation of the given value.
Assembly: EntityFramework (in EntityFramework.dll)
Name | Description | |
---|---|---|
![]() | AsText(DbGeography) | Gets the well-known text representation of the given DbGeography value. This value should include only the Longitude and Latitude of points. |
![]() | AsText(DbGeometry) | Gets the well-known text representation of the given DbGeometry value, including only X and Y coordinates for points. |
DbSpatialServices.AsText Method (DbGeography)
Gets the well-known text representation of the given DbGeography value. This value should include only the Longitude and Latitude of points.
Parameters
- geographyValue
-
Type:
System.Data.Entity.Spatial.DbGeography
The geography value for which the well-known text should be generated.
Return Value
Type: System.StringA string containing the well-known text representation of geographyValue.
Exception | Condition |
---|---|
ArgumentNullException | geographyValue is null. |
ArgumentException | geographyValue is not compatible with this spatial services implementation. |
DbSpatialServices.AsText Method (DbGeometry)
Gets the well-known text representation of the given DbGeometry value, including only X and Y coordinates for points.
Parameters
- geometryValue
-
Type:
System.Data.Entity.Spatial.DbGeometry
The geometry value for which the well-known text should be generated.
Return Value
Type: System.StringA string containing the well-known text representation of geometryValue.
Exception | Condition |
---|---|
ArgumentNullException | geometryValue is null. |
ArgumentException | geometryValue is not compatible with this spatial services implementation. |