Package oracle.spatial.network.lod
Class LogicalSubPathImpl
- java.lang.Object
-
- oracle.spatial.network.lod.LogicalSubPathImpl
-
- All Implemented Interfaces:
java.lang.Comparable
,LogicalLightSubPath
,LogicalSubPath
- Direct Known Subclasses:
SpatialSubPathImpl
public class LogicalSubPathImpl extends java.lang.Object implements LogicalSubPath
Default implementation of LogicalSubPath.- Since:
- 11gR1
-
-
Constructor Summary
Constructors Constructor Description LogicalSubPathImpl(LogicalPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, double[] costsOffRefPath, CategorizedUserData userData)
LogicalSubPathImpl(LogicalPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, CategorizedUserData userData)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description LogicalSubPath
append(LogicalSubPath subPath)
Appends a subpath to this subpath.java.lang.Object
clone()
Support cloneablejava.lang.Object
clone()
Support cloneableint
compareTo(java.lang.Object o)
CategorizedUserData
getCategorizedUserData()
Returns categorized user data.CategorizedUserData
getCategorizedUserData()
double
getCost()
Deprecated.double[]
getCosts()
Returns the costs of the subpath.double[]
getCostsToNode(int nodeIndex)
Returns the cumulative costs from the start point to the input node.int
getEndLinkIndex()
Returns the end link index.double
getEndPercentage()
Returns the location of the end point of the subpath as a percentage of the last link of the containing path.LogicalLightPath
getReferenceLightPath()
Returns the path containing the subpath.LogicalPath
getReferencePath()
Returns the path containing the subpath.int
getStartLinkIndex()
Returns the start link index.double
getStartPercentage()
Returns the location of the starting point of the subpath as a percentage of the first link of the containing path.UserData
getUserData(int category)
Returns user data for the specified category.UserData
getUserData(int category)
protected void
init(LogicalLightPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, CategorizedUserData userData)
boolean
isFullPath()
Returns true if the subpath covers the entire reference path.boolean
knowsIntermediateNodeCosts()
void
reverse()
Reverses the sub-path, and flip the isReverse flag of the reference path.void
setCategorizedUserData(CategorizedUserData userData)
Sets categorized user data.void
setCategorizedUserData(CategorizedUserData cud)
void
setCosts(double[] costs)
Sets the costs of the subpath.void
setEndLinkIndex(int endLinkIndex)
Sets the end link index.void
setEndPercentage(double endPercentage)
Sets the location of the end point of the subpath as a percentage of the last link of the containing path.void
setReferenceLightPath(LogicalLightPath refPath)
Sets the path containing the subpath.void
setStartLinkIndex(int startLinkIndex)
Sets the start link index.void
setStartPercentage(double startPercentage)
Sets the location of the starting point of the subpath as a percentage of the first link of the containing path.void
setUserData(int category, UserData userData)
Sets user data for the specified category.void
setUserData(int category, UserData userData)
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface oracle.spatial.network.lod.LogicalLightSubPath
getCost, getCosts, getEndLinkIndex, getEndPercentage, getReferenceLightPath, getStartLinkIndex, getStartPercentage, isFullPath, setCosts, setEndLinkIndex, setEndPercentage, setReferenceLightPath, setStartLinkIndex, setStartPercentage
-
-
-
-
Constructor Detail
-
LogicalSubPathImpl
public LogicalSubPathImpl(LogicalPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, double[] costsOffRefPath, CategorizedUserData userData)
-
LogicalSubPathImpl
public LogicalSubPathImpl(LogicalPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, CategorizedUserData userData)
-
-
Method Detail
-
knowsIntermediateNodeCosts
public boolean knowsIntermediateNodeCosts()
-
getReferencePath
public LogicalPath getReferencePath()
Description copied from interface:LogicalSubPath
Returns the path containing the subpath.- Specified by:
getReferencePath
in interfaceLogicalSubPath
- Returns:
- the logical path that contains the subpath
-
getCostsToNode
public double[] getCostsToNode(int nodeIndex)
Description copied from interface:LogicalSubPath
Returns the cumulative costs from the start point to the input node.- Specified by:
getCostsToNode
in interfaceLogicalSubPath
- Returns:
-
append
public LogicalSubPath append(LogicalSubPath subPath) throws LODNetworkException
Description copied from interface:LogicalSubPath
Appends a subpath to this subpath.- Specified by:
append
in interfaceLogicalSubPath
- Returns:
- Throws:
LODNetworkException
-
reverse
public void reverse()
Description copied from interface:LogicalLightSubPath
Reverses the sub-path, and flip the isReverse flag of the reference path. Similar to a path, a sub-path can be represented in the traveling direction, or in the reverse direction. When represented in reverse direction, the isReverse flag of its reference path is set to true.- Specified by:
reverse
in interfaceLogicalLightSubPath
-
getCategorizedUserData
public abstract CategorizedUserData getCategorizedUserData()
Returns categorized user data.- Returns:
-
setCategorizedUserData
public abstract void setCategorizedUserData(CategorizedUserData userData)
Sets categorized user data.- Parameters:
userData
-
-
getUserData
public abstract UserData getUserData(int category)
Returns user data for the specified category.- Returns:
-
setUserData
public abstract void setUserData(int category, UserData userData)
Sets user data for the specified category.- Parameters:
userData
-
-
clone
public abstract java.lang.Object clone() throws java.lang.CloneNotSupportedException
Support cloneable- Returns:
- cloned object
- Throws:
java.lang.CloneNotSupportedException
-
init
protected void init(LogicalLightPath referencePath, int startLinkIndex, double startPercentage, int endLinkIndex, double endPercentage, double[] costs, CategorizedUserData userData)
-
getReferenceLightPath
public LogicalLightPath getReferenceLightPath()
Description copied from interface:LogicalLightSubPath
Returns the path containing the subpath.- Specified by:
getReferenceLightPath
in interfaceLogicalLightSubPath
- Returns:
- the light weight logical path that contains the subpath
-
getStartPercentage
public double getStartPercentage()
Description copied from interface:LogicalLightSubPath
Returns the location of the starting point of the subpath as a percentage of the first link of the containing path.- Specified by:
getStartPercentage
in interfaceLogicalLightSubPath
- Returns:
- location of the starting point on the start link
-
getEndPercentage
public double getEndPercentage()
Description copied from interface:LogicalLightSubPath
Returns the location of the end point of the subpath as a percentage of the last link of the containing path.- Specified by:
getEndPercentage
in interfaceLogicalLightSubPath
- Returns:
- location of the end point on the end link
-
getStartLinkIndex
public int getStartLinkIndex()
Description copied from interface:LogicalLightSubPath
Returns the start link index.- Specified by:
getStartLinkIndex
in interfaceLogicalLightSubPath
- Returns:
- the start link index
-
getEndLinkIndex
public int getEndLinkIndex()
Description copied from interface:LogicalLightSubPath
Returns the end link index.- Specified by:
getEndLinkIndex
in interfaceLogicalLightSubPath
- Returns:
- the end link index
-
getCost
public double getCost()
Deprecated.Description copied from interface:LogicalLightSubPath
Returns the cost of the subpath.- Specified by:
getCost
in interfaceLogicalLightSubPath
- Returns:
- cost of the subpath
-
isFullPath
public boolean isFullPath()
Description copied from interface:LogicalLightSubPath
Returns true if the subpath covers the entire reference path.- Specified by:
isFullPath
in interfaceLogicalLightSubPath
- Returns:
- true if the subpath covers the entire reference path, false otherwise.
-
getCosts
public double[] getCosts()
Description copied from interface:LogicalLightSubPath
Returns the costs of the subpath.- Specified by:
getCosts
in interfaceLogicalLightSubPath
- Returns:
- costs of the subpath
-
setReferenceLightPath
public void setReferenceLightPath(LogicalLightPath refPath)
Description copied from interface:LogicalLightSubPath
Sets the path containing the subpath.- Specified by:
setReferenceLightPath
in interfaceLogicalLightSubPath
-
setStartPercentage
public void setStartPercentage(double startPercentage)
Description copied from interface:LogicalLightSubPath
Sets the location of the starting point of the subpath as a percentage of the first link of the containing path.- Specified by:
setStartPercentage
in interfaceLogicalLightSubPath
-
setEndPercentage
public void setEndPercentage(double endPercentage)
Description copied from interface:LogicalLightSubPath
Sets the location of the end point of the subpath as a percentage of the last link of the containing path.- Specified by:
setEndPercentage
in interfaceLogicalLightSubPath
-
setStartLinkIndex
public void setStartLinkIndex(int startLinkIndex)
Description copied from interface:LogicalLightSubPath
Sets the start link index.- Specified by:
setStartLinkIndex
in interfaceLogicalLightSubPath
-
setEndLinkIndex
public void setEndLinkIndex(int endLinkIndex)
Description copied from interface:LogicalLightSubPath
Sets the end link index.- Specified by:
setEndLinkIndex
in interfaceLogicalLightSubPath
-
setCosts
public void setCosts(double[] costs)
Description copied from interface:LogicalLightSubPath
Sets the costs of the subpath.- Specified by:
setCosts
in interfaceLogicalLightSubPath
-
compareTo
public int compareTo(java.lang.Object o)
- Specified by:
compareTo
in interfacejava.lang.Comparable
-
getCategorizedUserData
public CategorizedUserData getCategorizedUserData()
-
setCategorizedUserData
public void setCategorizedUserData(CategorizedUserData cud)
-
getUserData
public UserData getUserData(int category)
-
setUserData
public void setUserData(int category, UserData userData)
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
Support cloneable- Overrides:
clone
in classjava.lang.Object
- Returns:
- cloned object
- Throws:
java.lang.CloneNotSupportedException
-
-