Converts an ArcGIS Server SOAP geometry, SpatialReference, or GeoTransformation object to an ArcGIS Explorer object.

Namespace:  ESRI.ArcGISExplorer.Geometry

Assembly:  ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.1500 (2.0.0.1500)

Syntax

C#
public static TExplorer FromSoap<TExplorer>(
	Object soap
)
where TExplorer : class
Visual Basic (Declaration)
Public Shared Function FromSoap(Of TExplorer As Class) ( _
	soap As Object _
) As TExplorer

Parameters

soap
Type: System..::.Object

The SOAP object to convert to type TExplorer.

Type Parameters

TExplorer
The ArcGIS Explorer Type to convert soap to.

Return Value

An ArcGIS Explorer object of Type TExplorer based on the properties of the soap object.

Remarks

Use this generic method to convert SOAP PointN, MultipointN, PolylineN, PolygonN, EnvelopeN GeoTransformation or SpatialReference objects into corresponding ArcGIS Explorer objects.

Examples

The code below shows you how to convert SOAP geometry, SpatialReference or GeoTransformation objects into ArcGIS Explorer objects by using the FromSoap generic method. ArcGIS Explorer Types are fully-qualified to avoid confusion, with the exception of the SOAP types - you must ensure you have a using/Imports statement to your SOAP web reference namespace or fully-qualify the SOAP types in your own code.
CopyC#
// Remember you will need a using (Imports in Visual Basic) statement to the namespace of the SOAP definitions
// for your web references, e.g. the namespace containing the PointN SOAP type.

// NOTE - Set the SOAP PointN from the required web service here.
PointN soapPointN = new PointN();
// Convert the SOAP PointN to an ArcGIS Explorer Point.
ESRI.ArcGISExplorer.Geometry.Point xoPoint = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.Point>(soapPointN);

// NOTE - Set the SOAP MultipointN from the required web service here.
MultipointN soapMultipointN = new MultipointN();
// Convert the SOAP MultipointN to an ArcGIS Explorer Multipoint.
ESRI.ArcGISExplorer.Geometry.Multipoint xoMultipoint = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.Multipoint>(soapMultipointN);

// NOTE - Set the SOAP EnvelopeN from the required web service here.
EnvelopeN soapEnvelopeN = new EnvelopeN();
// Convert the SOAP EnvelopeN to an ArcGIS Explorer Envelope.
ESRI.ArcGISExplorer.Geometry.Envelope xoEnvelope = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.Envelope>(soapEnvelopeN);

// NOTE - Set the SOAP PolylineN from the required web service here.
PolylineN soapPolylineN = new PolylineN();
// Convert the SOAP PolylineN to an ArcGIS Explorer Polyline.
ESRI.ArcGISExplorer.Geometry.Polyline xoPolyline = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.Polyline>(soapPolylineN);

// NOTE - Set the SOAP PolygonN from the required web service here.
PolygonN soapPolygonN = new PolygonN();
// Convert the SOAP PolygonN to an ArcGIS Explorer Polygon.
ESRI.ArcGISExplorer.Geometry.Polygon xoPolygon = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.Polygon>(soapPolygonN);

// NOTE - Set the SOAP SpatialReference from the required web service here.
SpatialReference soapSpatialReference = new ProjectedCoordinateSystem();
// Convert the SOAP SpatialReference to an ArcGIS Explorer CoordinateSystem.
ESRI.ArcGISExplorer.Geometry.CoordinateSystem xoCoordinateSystem = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.CoordinateSystem>(soapSpatialReference);

// NOTE - Set the SOAP GeoTransformation from the required web service here.
GeoTransformation soapGeoTransformation = new GeoTransformation();
// Convert the SOAP GeoTransformation to an ArcGIS Explorer GeographicTransformation.
ESRI.ArcGISExplorer.Geometry.GeographicTransformation xoGeographicTransformation = SoapConverter.FromSoap<ESRI.ArcGISExplorer.Geometry.GeographicTransformation>(soapGeoTransformation);
CopyVB.NET
' Remember you will need a using (Imports in Visual Basic) statement to the namespace of the SOAP definitions
' for your web references, e.g. the namespace containing the PointN SOAP type.


' NOTE - Set the SOAP PointN from the required web service here.
Dim soapPointN As PointN = New PointN()
' Convert the SOAP PointN to an ArcGIS Explorer Point.
Dim xoPoint As ESRI.ArcGISExplorer.Geometry.Point = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.Point)(soapPointN)

' NOTE - Set the SOAP MultipointN from the required web service here.
Dim soapMultipointN As MultipointN = New MultipointN()
' Convert the SOAP MultipointN to an ArcGIS Explorer Multipoint.
Dim xoMultipoint As ESRI.ArcGISExplorer.Geometry.Multipoint = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.Multipoint)(soapMultipointN)

' NOTE - Set the SOAP EnvelopeN from the required web service here.
Dim soapEnvelopeN As EnvelopeN = New EnvelopeN()
' Convert the SOAP EnvelopeN to an ArcGIS Explorer Envelope.
Dim xoEnvelope As ESRI.ArcGISExplorer.Geometry.Envelope = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.Envelope)(soapEnvelopeN)

' NOTE - Set the SOAP PolylineN from the required web service here.
Dim soapPolylineN As PolylineN = New PolylineN()
' Convert the SOAP PolylineN to an ArcGIS Explorer Polyline.
Dim xoPolyline As ESRI.ArcGISExplorer.Geometry.Polyline = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.Polyline)(soapPolylineN)

' NOTE - Set the SOAP PolygonN from the required web service here.
Dim soapPolygonN As PolygonN = New PolygonN()
' Convert the SOAP PolygonN to an ArcGIS Explorer Polygon.
Dim xoPolygon As ESRI.ArcGISExplorer.Geometry.Polygon = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.Polygon)(soapPolygonN)

' NOTE - Set the SOAP SpatialReference from the required web service here.
Dim soapSpatialReference As SpatialReference = New ProjectedCoordinateSystem()
' Convert the SOAP SpatialReference to an ArcGIS Explorer CoordinateSystem.
Dim xoCoordinateSystem As ESRI.ArcGISExplorer.Geometry.CoordinateSystem = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.CoordinateSystem)(soapSpatialReference)

' NOTE - Set the SOAP GeoTransformation from the required web service here.
Dim soapGeoTransformation As GeoTransformation = New GeoTransformation()
' Convert the SOAP GeoTransformation to an ArcGIS Explorer GeographicTransformation.
Dim xoGeographicTransformation As ESRI.ArcGISExplorer.Geometry.GeographicTransformation = SoapConverter.FromSoap(Of ESRI.ArcGISExplorer.Geometry.GeographicTransformation)(soapGeoTransformation)

See Also