ArcFM Server Developer Guide
SOAP API

Version: 10.6.1 SP1

Resource Center Home

Use the SOAP API if you're developing a custom ArcFM Server web application in a non-.NET environment (e.g., Flex, Java) and without the ArcFM for Silverlight SDK. 

Miner.Server.ADF.ArcFMServer contains the ArcFM Server proxies and value objects. If you're developing on an ArcFM Server client, you can use this assembly. If you are NOT developing on an ArcFM Server client machine, then you can import ArcFMMapServer.wsdl and create your own proxies. By default, ArcFMMapServer.wsdl is installed here: C:\Program Files\ArcGIS\XmlSchema.

The following code sample shows how you might run an upstream trace using SOAP API.

Upstream Trace
Copy Code
public class ElectricTrace : IElectricTrace
{
    public Miner.Server.ADF.ArcFMServer.ResultSet[] ElectricUpstreamTrace
        (Esri.ArcGIS.ADF.ArcGISServer.PointN startpoint,
        Miner.Server.ADF.ArcFMServer.ElectricUpstreamTraceOptions traceOptions)
    {
        // Initialize our return value of an array of ArcFMMapServer ResultSets,
        // which itself is an array of Esri Records, a value object representing the feature geometry and attributes
        Miner.Server.ADF.ArcFMServer.ResultSet[] results = null;

        // If we didn't get trace options in, set them to some reasonable default values
        if (traceOptions == null) traceOptions = DefaultElectricUpstreamTraceOptions();

        // Create an ArcFM MapServerProxy and pass it the url for the endpoint
        // the form of the endpoint is http://<machine_name>/arcgis/services/<service_name>/MapServer/ArcFMMapServer
        // another way to look at this is <MapServerURL>\ArcFMMapServer
        string endpoint = "http://localhost/arcgis/services/Electric/MapServer/ArcFMMapServer";
        Miner.Server.ADF.ArcFMServer.MapServerProxy mapServerProxy =
            new Miner.Server.ADF.ArcFMServer.MapServerProxy(endpoint);

        // Call the Upstream Trace method on the MapServerProxy
        results = mapServerProxy.UpstreamTrace(startpoint, traceOptions);

        return results;
    }

    private Miner.Server.ADF.ArcFMServer.ElectricUpstreamTraceOptions DefaultElectricUpstreamTraceOptions()
    {
        Miner.Server.ADF.ArcFMServer.ElectricUpstreamTraceOptions electricUpstreamTraceOptions =
            new Miner.Server.ADF.ArcFMServer.ElectricUpstreamTraceOptions();

        electricUpstreamTraceOptions.RespectConductorPhasing = true;
        electricUpstreamTraceOptions.RespectEnabledField = true;
        electricUpstreamTraceOptions.RespectEsriBarriers = true;
        electricUpstreamTraceOptions.PhasesToTrace =
            Miner.Server.ADF.ArcFMServer.mmPhasesToTrace.mmPTT_Any;

        electricUpstreamTraceOptions.DrawBuffer = 0.0;
        electricUpstreamTraceOptions.DrawComplexEdges = true;
        electricUpstreamTraceOptions.DrawGraphics = true;
        electricUpstreamTraceOptions.FeaturesStoppingTrace = false;
        electricUpstreamTraceOptions.IncludeEdges = true;
        electricUpstreamTraceOptions.IncludeJunctions = true;
        electricUpstreamTraceOptions.RespectEnabledField = true;
        electricUpstreamTraceOptions.ReturnGeometries = true;
        electricUpstreamTraceOptions.ReturnAttributes = true;

        return electricUpstreamTraceOptions;
    }
}

 

 

 

 

 


Send Comment to ArcFMdocumentation@schneider-electric.com