本文整理汇总了C#中System.Data.Spatial.DbGeometry类的典型用法代码示例。如果您正苦于以下问题:C# DbGeometry类的具体用法?C# DbGeometry怎么用?C# DbGeometry使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DbGeometry类属于System.Data.Spatial命名空间,在下文中一共展示了DbGeometry类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AsGml
public override string AsGml(DbGeometry geometryValue)
{
CheckParameterNotNull("geometryValue", geometryValue);
dynamic providerValue = geometryValue.ProviderValue;
return providerValue.AsGml().Value;
}
示例2: Buffer
public override DbGeometry Buffer(DbGeometry geometryValue, double distance)
{
CheckParameterNotNull("geometryValue", geometryValue);
dynamic providerValue = geometryValue.ProviderValue;
return GeometryFromProviderValue(providerValue.STBuffer(distance));
}
示例3: AsText
public override string AsText(DbGeometry geometryValue)
{
CheckParameterNotNull("geometryValue", geometryValue);
dynamic providerValue = geometryValue.ProviderValue;
return providerValue.STAsText().ToSqlString().Value;
}
示例4: AsBinary
public override byte[] AsBinary(DbGeometry geometryValue)
{
CheckParameterNotNull("geographyValue", geometryValue);
dynamic providerValue = geometryValue.ProviderValue;
return providerValue.STAsBinary().Value;
}
示例5: AsText
public override string AsText(DbGeometry geometryValue)
{
if (geometryValue == null)
throw new ArgumentNullException("geometryValue");
var providerValue = new MySqlGeometry();
MySqlGeometry.TryParse(geometryValue.ProviderValue.ToString(), out providerValue);
return providerValue.ToString();
}
示例6: CheckCompatible
private static ReadOnlySpatialValues CheckCompatible(DbGeometry geometryValue)
{
Debug.Assert(geometryValue != null, "Validate geometryValue is non-null before calling CheckCompatible");
if (geometryValue != null)
{
ReadOnlySpatialValues expectedValue = geometryValue.ProviderValue as ReadOnlySpatialValues;
if (expectedValue != null)
{
return expectedValue;
}
}
throw SpatialExceptions.GeometryValueNotCompatibleWithSpatialServices("geometryValue");
}
示例7: InteriorRingAt
public override DbGeometry InteriorRingAt(DbGeometry geometryValue, int index)
{
throw SpatialServicesUnavailable();
}
示例8: GetExteriorRing
public override DbGeometry GetExteriorRing(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}
示例9: GetCentroid
public override DbGeometry GetCentroid(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}
示例10: PointAt
public override DbGeometry PointAt(DbGeometry geometryValue, int index)
{
throw SpatialServicesUnavailable();
}
示例11: GetIsRing
public override bool? GetIsRing(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}
示例12: AsBinary
public override byte[] AsBinary(DbGeometry geometryValue)
{
geometryValue.CheckNull("geometryValue");
ReadOnlySpatialValues expectedValue = CheckCompatible(geometryValue);
return expectedValue.CloneBinary();
}
示例13: GetSpatialTypeName
public override string GetSpatialTypeName(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}
示例14: GetEnvelope
public override DbGeometry GetEnvelope(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}
示例15: GetDimension
public override int GetDimension(DbGeometry geometryValue)
{
throw SpatialServicesUnavailable();
}