Class FacilityAnalyst3D
- java.lang.Object
-
- com.supermap.data.InternalHandle
-
- com.supermap.data.InternalHandleDisposable
-
- com.supermap.analyst.networkanalyst3d.FacilityAnalyst3D
-
public class FacilityAnalyst3D extends InternalHandleDisposable
The FacilityAnalyst3D class is used for checking data, finding the edges between node/edge and source/sink, tracing upstream, tracing downstream, finding the upstream closest facility, etc.
The facility network is the simulation for the real-world common network and infrastructure, such as water supply networks, power lines, communication lines, gas pipelines, rivers, etc., whose common feature is the flow of resources has direction.
The 3D facility network analysis is based on the 3D network dataset, which is the important content of 3D network analysis. Its main functions are: finding the edges between node/edge and source/sink, tracing upstream, tracing downstream, finding the upstream closest facility, etc.
Comparing with conventional 2D facility network analysis, the 3D facility network analysis has a real 3D display, which is better in providing the guidance and decision support for the design, construction and emergency management of the facility network.
The procedures of the 3D facility network analysis:1. (Optional) Checks the data for the network dataset to be analyzed (the Check method).
2. Sets the environment of the 3D facility network analysis (
setAnalystSetting()
method).3.Loads the network model (the
load()
method);4. Performs the various facility network analysis method provided by the FacilityAnalyst3D class.
-
-
Constructor Summary
Constructors Constructor and Description FacilityAnalyst3D()
Creates a new FacilityAnalyst3D object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description FacilityAnalystCheckResult3D
check()
Checks the data for the 3D facility network dataset, and returns the results object of the Check class.void
dispose()
Releases the object.FacilityAnalystResult3D
findCriticalFacilitiesUpFromEdge(int[] sourceNodeIDs, int edgeID, boolean isUncertainDirectionValid)
Upstream analysis of facility network, which aims at finding the closest facility node in the upstream.FacilityAnalystResult3D
findCriticalFacilitiesUpFromNode(int[] sourceNodeIDs, int nodeID, boolean isUncertainDirectionValid)
Upstream analysis of facility network, which aims at finding the closest facility node in the upstream.FacilityAnalystResult3D
findSinkFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds sink based on edges.FacilityAnalystResult3D
findSinkFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds the join between nodes.FacilityAnalystResult3D
findSourceFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds source based on edges.FacilityAnalystSetting3D
getAnalystSetting()
Returns the analysis environment settings object.boolean
load()
Loads the network model.void
setAnalystSetting(FacilityAnalystSetting3D value)
Sets the analysis environment settings object.FacilityAnalystResult3D
traceDownFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the passed edges by tracing the downstream of the specified node or edge.FacilityAnalystResult3D
traceDownFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the downstream of the specified node.FacilityAnalystResult3D
traceUpFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the upstreams of the specified node.FacilityAnalystResult3D
traceUpFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the upstreams of the specified node.
-
-
-
Constructor Detail
-
FacilityAnalyst3D
public FacilityAnalyst3D()
Creates a new FacilityAnalyst3D object.
-
-
Method Detail
-
getAnalystSetting
public FacilityAnalystSetting3D getAnalystSetting()
Returns the analysis environment settings object.- Returns:
- The analysis environment settings object.
-
setAnalystSetting
public void setAnalystSetting(FacilityAnalystSetting3D value)
Sets the analysis environment settings object.- Parameters:
value
- The analysis environment settings object.
-
load
public boolean load()
Loads the network model. This method is called after setting the AnalystSetting, and is used to load the network model according to the environment parameters in the AnalystSetting object.- Returns:
- boolean Returns a Boolean value that returns true if the load succeeds; otherwise, false.
-
check
public FacilityAnalystCheckResult3D check()
Checks the data for the 3D facility network dataset, and returns the results object of the Check class.- Returns:
- The data check result of the 3D facility network analysis.
-
findSourceFromEdge
public FacilityAnalystResult3D findSourceFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds source based on edges. When you pass in edge ID, the array of IDs of edges from edge to source will be returned.- Parameters:
edgeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- The ID array between the specified edge and sink.
-
findSinkFromNode
public FacilityAnalystResult3D findSinkFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds the join between nodes. When you pass in node IDs, the array of IDs of edges from node to sink will be returned.- Parameters:
nodeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- The edge ID array between the node and sink.
-
findSinkFromEdge
public FacilityAnalystResult3D findSinkFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds sink based on edges. When you pass in edge ID, the array of IDs of edges from edge to sink will be returned.- Parameters:
edgeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- The ID array of edges between edge and sink.
-
traceUpFromNode
public FacilityAnalystResult3D traceUpFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the upstreams of the specified node. The result is the array of the edge IDs.- Parameters:
nodeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- ID array of all edges in the upstream of and flow through the specified node.
-
traceUpFromEdge
public FacilityAnalystResult3D traceUpFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the upstreams of the specified node. ID array of edges in the upstream of the specified edge will return.- Parameters:
edgeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- ID array of all edges in the upstream of the specified node.
-
traceDownFromNode
public FacilityAnalystResult3D traceDownFromNode(int nodeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the edges by tracing the downstream of the specified node. The result is the array of the edge IDs.- Parameters:
nodeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- ID array of all edges in the upstream of and flow through the specified node.
-
traceDownFromEdge
public FacilityAnalystResult3D traceDownFromEdge(int edgeID, java.lang.String weightName, boolean isUncertainDirectionValid)
Finds all the passed edges by tracing the downstream of the specified node or edge. The result is the array of the edge IDs.- Parameters:
edgeID
- Pass ID.weightName
- The name of Weight Field Info.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- ID array of all passed edges in the downstream of the specified node or edge.
-
findCriticalFacilitiesUpFromNode
public FacilityAnalystResult3D findCriticalFacilitiesUpFromNode(int[] sourceNodeIDs, int nodeID, boolean isUncertainDirectionValid)
Upstream analysis of facility network, which aims at finding the closest facility node in the upstream. Users can specify a node or edge ID, and find closest upstream facility node from the node array that satisfying the condition.- Parameters:
sourceNodeIDs
- The ID array of nodes satisfying the condition. The result is a child set of this sourceNodeIDs array. If the array passed in is null, all nodes will be queried.nodeID
- Passed ID.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- Closest upstream facility node.
-
findCriticalFacilitiesUpFromEdge
public FacilityAnalystResult3D findCriticalFacilitiesUpFromEdge(int[] sourceNodeIDs, int edgeID, boolean isUncertainDirectionValid)
Upstream analysis of facility network, which aims at finding the closest facility node in the upstream. Users can specify a node or edge ID, and find closest upstream facility node from the node array that satisfying the condition.- Parameters:
sourceNodeIDs
- The ID array of nodes satisfying the condition. The result is a child set of this sourceNodeIDs array. If the array passed in is null, all nodes will be queried.edgeID
- Passed ID.isUncertainDirectionValid
- Whether the loop is valid.- Returns:
- Closest upstream facility node.
-
dispose
public void dispose()
Releases the object.
-
-