Class: networkAnalystService

L.supermap.networkAnalystService

The NetworkAnalystService class.

L.supermap.networkAnalystService(url, options)

NetworkAnalystService.js, line 19
Name Type Description
url string

The url of service. The url to request NetworkAnalystService should be:
http://{service URL}:{server port}/iserver/services/{NetworkAnalystService name}/rest/networkanalyst/{dataSet name@dataSource name}.
For example: "http://localhost:8090/iserver/services/test/rest/networkanalyst/WaterNet@FacilityNet";

options Object

The optional parameters.

Name Type Default Description
proxy string optional

Service agent address.

serverType SuperMap.ServerType SuperMap.ServerType.ISERVER optional

Type of server iServer|iPortal|online。

withCredentials boolean false optional

Request whether to carry a cookie.

crossOrigin boolean optional

Whether to allow cross-domain requests.

headers Object optional

Request header.

Example
L.supermap.networkAnalystService(url)
 .findPath(params,function(result){
    //doSomething
})

Extends

Events

inherited destroy

ServiceBase.js, line 49

Triggered after the resource is successfully released.

Properties:
Name Type Description
this L.supermap.ServiceBase

This object.

inherited initialized

ServiceBase.js, line 36

Triggered after the constructor is constructed successfully.

Properties:
Name Type Description
this L.supermap.ServiceBase

This object.

Methods

burstPipelineAnalyst(params, callback)

NetworkAnalystService.js, line 45

Analysis the burst pipeline: analyze the given edge or node as the pipeline burst node, and return the critical node ID array, common node ID array and upstream/downstream edge ID array.

Name Type Description
params SuperMap.BurstPipelineAnalystParameters

The BurstPipelineAnalystParameters class.

callback RequestCallback

The callback of result data returned by the server side.

computeWeightMatrix(params, callback)

NetworkAnalystService.js, line 66

Compute weight of matrix. The costs matrix refers to a 2D matrix computed by the costs fields in the traffic network analysis parameters, which is used to store the resources costs between each pairs of the specified points.

Name Type Description
params SuperMap.ComputeWeightMatrixParameters

The ComputeWeightMatrixParameters class.

callback RequestCallback

The callback of result data returned by the server side.

inherited destroy()

ServiceBase.js, line 44

Disposes the resource. The property that references resource is set to null.

findClosestFacilities(params, callback, resultFormat)

NetworkAnalystService.js, line 87

Find closest facilities. It is used to find the closest facilities from the selected ones for the specified event site(s) in the network. The closest facilities are those that have the least impedance in the specified direction -- either from the event site to the facility or from the facility to the event site.

Name Type Default Description
params SuperMap.FindClosestFacilitiesParameters

The FindClosestFacilitiesParameters class.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

findLocation(params, callback, resultFormat)

NetworkAnalystService.js, line 133

Find location. It is used to find the optimal location from multiple candidate locations for a facility, by matching the supply and demand based on the objectives and constraints.

Name Type Default Description
params SuperMap.FindLocationParameters

The parameters of findLocation.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

findPath(params, callback, resultFormat)

NetworkAnalystService.js, line 156

Find optimal path. The optimal path analysis refers to finding the path with the minimum cumulative impedance by visiting all the specified nodes in order.

Name Type Default Description
params SuperMap.FindPathParameters

The FindPathParameters class.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

findServiceAreas(params, callback, resultFormat)

NetworkAnalystService.js, line 225

Find service areas. It is a kind of network analysis, used to determine the area that can be served by a service site based on specified criteria.

Name Type Default Description
params SuperMap.FindServiceAreasParameters

The FindServiceAreasParameters class.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

findTSPPaths(params, callback, resultFormat)

NetworkAnalystService.js, line 179

Find paths of traveler. TSP is an unordered route analysis. It starts from the Start point (the default is the first point that you specify), and finds a route that traverses all nodes with minimum cost. You may also specify an End point. Thus, It finds a route that traverses all nodes and arrives at the End point with minimum cost.

Name Type Default Description
params SuperMap.FindTSPPathsParameters

The FindTSPPathsParameters class.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

streamFacilityAnalyst(params, callback, resultFormat)

NetworkAnalystService.js, line 110

Find key facilities in the upstream and downstream. It returns the key node ID array and its downstream arc segment ID array by finding key facility nodes in the upstream/downstream of a given arc or node.

Name Type Default Description
params SuperMap.FacilityAnalystStreamParameters

The FacilityAnalystStreamParameters class.

callback RequestCallback

The callback of result data returned by the server side.

resultFormat SuperMap.DataFormat SuperMap.DataFormat.GEOJSON optional

The format of result data.

updateEdgeWeight(params, callback)

NetworkAnalystService.js, line 248

Update the weight of edge.

Name Type Description
params SuperMap.UpdateEdgeWeightParameters

The UpdateEdgeWeightParameters class.

callback RequestCallback

The callback of result data returned by the server side.

updateTurnNodeWeight(params, callback)

NetworkAnalystService.js, line 269

Update the weight of turn node.

Name Type Description
params SuperMap.UpdateTurnNodeWeightParameters

The UpdateTurnNodeWeightParameters class.

callback RequestCallback

The callback of result data returned by the server side.