Oracle® Spatial Java API Reference
10g Release 2 (10.2)

B14373-02


oracle.spatial.network
Interface Path

All Superinterfaces:
java.lang.Cloneable, java.lang.Comparable, java.io.Serializable

public interface Path
extends java.lang.Cloneable, java.io.Serializable, java.lang.Comparable

This interface defines a network path.


Method Summary
 java.lang.Object clone()
          Clones the path.
 void computeGeometry(double tolerance)
          Computes the path geometry from its link geometries.
 boolean contains(Link l)
          Checks if the path contains the specified link.
 boolean contains(Node n)
          Checks if the path contains the specified node.
 boolean contains(Path path)
          Checks if the path contains the specified path.
 double getCost()
          Returns the path cost.
 double getDuration()
          Gets path duration information
 Node getEndNode()
          Returns the end node of the path.
 JGeometry getGeometry()
          Returns the path geometry (JGeometry).
 int getID()
          Returns the path ID.
 Link[] getLinkArray()
          Returns the path links as an array.
 Link getLinkAt(int index)
           
 java.util.Iterator getLinks()
          Returns the path links as an Iterator.
 java.lang.String getName()
          Returns the path name.
 Network getNetwork()
          Returns the network that contains the path.
 Node[] getNodeArray()
          Returns the path nodes as an array.
 Node getNodeAt(int index)
          Returns the specified node of the path.
 java.util.Iterator getNodes()
          Returns the path nodes as an Iterator.
 int getNoOfLinks()
          Returns the number of links in the path.
 Node getStartNode()
          Returns the start node of the path.
 boolean getState()
          Gets the path state.
 java.lang.String getType()
          Returns the path type.
 java.lang.Object getUserData()
          Gets user defined data.
 java.lang.Object getUserData(java.lang.String name)
          Gets user data
 boolean isActive()
          Checks if the path is active.
 boolean isClosed()
          Checks if the path is closed.
 boolean isConnected(Path path)
          Checks if the path is connected.
 boolean isLogical()
          Chceks if the path is logical.
 boolean isSimple()
          Checks if the path is simple (no self-crossing).
 boolean isTemporary()
          Checks if the path is temporary.
 void setGeometry(JGeometry geom)
          Sets the path geometry (JGeometry).
 void setID(int id)
          Sets the path ID.
 void setName(java.lang.String name)
          Sets the path name.
 void setType(java.lang.String type)
          Sets the path type.
 void setUserData(java.lang.Object userData)
          Sets user defined data.
 void setUserData(java.lang.String name, java.lang.Object data)
          Sets user data
 int size()
          Returns the number of links in the path

 

Methods inherited from interface java.lang.Comparable
compareTo

 

Method Detail

getID

int getID()
Returns the path ID.

setID

void setID(int id)
           throws NetworkDataException
Sets the path ID.
Parameters:
id - the path ID to be set
Throws:
NetworkDataException

getName

java.lang.String getName()
Returns the path name.

setName

void setName(java.lang.String name)
Sets the path name.
Parameters:
name - the path name to be set

getType

java.lang.String getType()
Returns the path type.

setType

void setType(java.lang.String type)
Sets the path type.
Parameters:
type - the path type to be set

getLinkAt

Link getLinkAt(int index)

getNodeAt

Node getNodeAt(int index)
Returns the specified node of the path.
Parameters:
index - the specified node position

isClosed

boolean isClosed()
Checks if the path is closed.

getStartNode

Node getStartNode()
Returns the start node of the path.

getEndNode

Node getEndNode()
Returns the end node of the path.

getNetwork

Network getNetwork()
Returns the network that contains the path.

getLinkArray

Link[] getLinkArray()
Returns the path links as an array.

getLinks

java.util.Iterator getLinks()
Returns the path links as an Iterator.

getNodeArray

Node[] getNodeArray()
Returns the path nodes as an array.

getNodes

java.util.Iterator getNodes()
Returns the path nodes as an Iterator.

getNoOfLinks

int getNoOfLinks()
Returns the number of links in the path.

size

int size()
Returns the number of links in the path

getCost

double getCost()
Returns the path cost.

isConnected

boolean isConnected(Path path)
Checks if the path is connected.

isSimple

boolean isSimple()
Checks if the path is simple (no self-crossing).

isTemporary

boolean isTemporary()
Checks if the path is temporary.

contains

boolean contains(Node n)
Checks if the path contains the specified node.
Parameters:
n - the specified node

contains

boolean contains(Link l)
Checks if the path contains the specified link.
Parameters:
l - the specified link

contains

boolean contains(Path path)
Checks if the path contains the specified path.
Parameters:
path - the specified path

clone

java.lang.Object clone()
Clones the path.

getGeometry

JGeometry getGeometry()
Returns the path geometry (JGeometry).

setGeometry

void setGeometry(JGeometry geom)
Sets the path geometry (JGeometry).

isLogical

boolean isLogical()
Chceks if the path is logical.

isActive

boolean isActive()
Checks if the path is active.

getUserData

java.lang.Object getUserData()
Gets user defined data.
Returns:
userData the user data.

setUserData

void setUserData(java.lang.Object userData)
Sets user defined data.
Parameters:
userData - the user data.

getState

boolean getState()
Gets the path state.

computeGeometry

void computeGeometry(double tolerance)
Computes the path geometry from its link geometries.
Parameters:
tolerance - the tolerance for testing if two points are the same.

getDuration

double getDuration()
Gets path duration information

setUserData

void setUserData(java.lang.String name,
                 java.lang.Object data)
Sets user data
Parameters:
name - name for the user data
data - user data

getUserData

java.lang.Object getUserData(java.lang.String name)
Gets user data
Parameters:
name - name for the user data
Returns:
user data as an Java Object

Oracle® Spatial Java API Reference
10g Release 2 (10.2)

B14373-02


Copyright © 2006, Oracle. All Rights Reserved.