SuperMap.WinRT.REST.Bridge.ToGeometry C# (CSharp) Method

ToGeometry() public static method

${REST_Bridge_method_ServerGeometryToGeometry_D}
public static ToGeometry ( this geo ) : Geometry
geo this ${REST_Bridge_method_ServerGeometryToGeometry_param_geo}
return SuperMap.WinRT.Core.Geometry
        public static SuperMap.WinRT.Core.Geometry ToGeometry(this ServerGeometry geo)
        {
            if (geo != null)
            {
                if (geo.Type == ServerGeometryType.POINT)
                {
                    return geo.ToGeoPoint();
                }
                else if (geo.Type == ServerGeometryType.REGION)
                {
                    return geo.ToGeoRegion();
                }
                else if (geo.Type == ServerGeometryType.LINE || geo.Type == ServerGeometryType.LINEM)
                {
                    return geo.ToGeoLine();
                }
            }
            return null;
        }