Package oracle.spatial.network.lod
Class LODNetworkWrapper
- java.lang.Object
-
- oracle.spatial.network.lod.LODNetworkWrapper
-
public class LODNetworkWrapper extends java.lang.ObjectThis is the wrapper class containing LOD related java stored procedures used by SDO_NET package.- Since:
- 11gR1
-
-
Field Summary
Fields Modifier and Type Field Description static intLEVEL_DEBUGstatic intLEVEL_ERRORstatic intLEVEL_FATALstatic intLEVEL_FINESTstatic intLEVEL_INFOstatic intLEVEL_WARN
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidfindConnectedComponents(java.lang.String networkName, int linkLevel, java.lang.String componentTable)Finds the connected components and writes the node component relationship into component table.static intfindConnectedComponentsInPartition(java.lang.String networkName, int linkLevel, int partitionId, int startComponentId, java.sql.Array[] nodeArray, java.sql.Array[] componentArray)Find the connected components within a partition, with all the external nodes and boundary links included.static voidgeneratePartitionBlob(java.lang.String networkName, int linkLevel, int partitionId, boolean includeUserData)Writes partition BLOBs into partition blob table.static voidgeneratePartitionBlob(java.lang.String networkName, int linkLevel, int partitionId, boolean includeUserData, boolean performDeltaUpdate)Writes partition BLOBs into partition blob table.static voidgeneratePartitionBlobs(java.lang.String networkName, int linkLevel, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob)Writes partition BLOBs into partition blob table.static voidgeneratePartitionBlobs(java.lang.String networkName, int linkLevel, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob, boolean performDeltaUpdate)Writes partition BLOBs into partition blob table.static voidgeneratePartitionBlobs(java.lang.String networkName, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob, boolean performDeltaUpdate)Writes partition BLOBs into partition blob table.static longgetPartitionSize(java.lang.String networkName, int partitionId, int linkLevel, boolean includeUserData, boolean includeSpatialData)Returns the approximated size of a network partition in bytesstatic voidloadConfig(java.sql.Clob configXml)Reloads the configuration xml.static voidsetConnection(java.sql.Connection conn)Sets the JDBC connection to the database.static voidsetLoggingLevel(int level)Sets java global logging level.
-
-
-
Field Detail
-
LEVEL_FATAL
public static final int LEVEL_FATAL
- See Also:
- Constant Field Values
-
LEVEL_ERROR
public static final int LEVEL_ERROR
- See Also:
- Constant Field Values
-
LEVEL_WARN
public static final int LEVEL_WARN
- See Also:
- Constant Field Values
-
LEVEL_INFO
public static final int LEVEL_INFO
- See Also:
- Constant Field Values
-
LEVEL_DEBUG
public static final int LEVEL_DEBUG
- See Also:
- Constant Field Values
-
LEVEL_FINEST
public static final int LEVEL_FINEST
- See Also:
- Constant Field Values
-
-
Method Detail
-
setConnection
public static void setConnection(java.sql.Connection conn)
Sets the JDBC connection to the database.- Parameters:
conn- connection to the database. It must be an OracleConnection.
-
setLoggingLevel
public static void setLoggingLevel(int level)
Sets java global logging level.- Parameters:
level- LOD logging level, which can take the following values:- LODNetworkWrapper.LEVEL_FATAL = 1;
- LODNetworkWrapper.LEVEL_ERROR = 2;
- LODNetworkWrapper.LEVEL_WARN = 3;
- LODNetworkWrapper.LEVEL_INFO = 4;
- LODNetworkWrapper.LEVEL_DEBUG = 5;
- LODNetworkWrapper.LEVEL_FINEST = 6;
-
loadConfig
public static void loadConfig(java.sql.Clob configXml) throws LODNetworkExceptionReloads the configuration xml.- Parameters:
configXml- configuration xml- Throws:
LODNetworkException
-
generatePartitionBlob
public static void generatePartitionBlob(java.lang.String networkName, int linkLevel, int partitionId, boolean includeUserData) throws LODNetworkExceptionWrites partition BLOBs into partition blob table. The caller needs to make sure that the partition blob table already exists before calling this method.- Parameters:
networkName- network namelinkLevel- link levelpartitionId- partition IDincludeUserData- is user defined data included in the BLOB- Throws:
LODNetworkException
-
generatePartitionBlobs
public static void generatePartitionBlobs(java.lang.String networkName, int linkLevel, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob) throws LODNetworkExceptionWrites partition BLOBs into partition blob table. The caller needs to make sure that the partition blob table already exists before calling this method.- Parameters:
networkName- network namelinkLevel- link levelpartitionBlobTable- partition BLOB table nameincludeUserData- is user defined data included in the BLOBs- Throws:
LODNetworkException
-
generatePartitionBlob
public static void generatePartitionBlob(java.lang.String networkName, int linkLevel, int partitionId, boolean includeUserData, boolean performDeltaUpdate) throws LODNetworkExceptionWrites partition BLOBs into partition blob table. The caller needs to make sure that the partition blob table already exists before calling this method.- Parameters:
networkName- network namelinkLevel- link levelpartitionId- partition IDincludeUserData- is user defined data included in the BLOBperformDeltaUpdate- whether to use network update history to perform delta update on existing BLOBs or to reload the network information directly from the network node and link tables/views.- Throws:
LODNetworkException- Since:
- 11gR2
-
generatePartitionBlobs
public static void generatePartitionBlobs(java.lang.String networkName, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob, boolean performDeltaUpdate) throws LODNetworkExceptionWrites partition BLOBs into partition blob table. The caller needs to make sure that the partition blob table already exists before calling this method.- Parameters:
networkName- network namepartitionBlobTable- partition BLOB table nameincludeUserData- is user defined data included in the BLOBscommitForEachBlob- whether to call commit after writing the BLOB for each partitionperformDeltaUpdate- whether to use network update history to perform delta update on existing BLOBs or to reload the network information directly from the network node and link tables/views.- Throws:
LODNetworkException- Since:
- 11gR2
-
generatePartitionBlobs
public static void generatePartitionBlobs(java.lang.String networkName, int linkLevel, java.lang.String partitionBlobTable, boolean includeUserData, boolean commitForEachBlob, boolean performDeltaUpdate) throws LODNetworkExceptionWrites partition BLOBs into partition blob table. The caller needs to make sure that the partition blob table already exists before calling this method.- Parameters:
networkName- network namelinkLevel- link levelpartitionBlobTable- partition BLOB table nameincludeUserData- is user defined data included in the BLOBscommitForEachBlob- whether to call commit after writing the BLOB for each partitionperformDeltaUpdate- whether to use network update history to perform delta update on existing BLOBs or to reload the network information directly from the network node and link tables/views.- Throws:
LODNetworkException- Since:
- 11gR2
-
findConnectedComponents
public static void findConnectedComponents(java.lang.String networkName, int linkLevel, java.lang.String componentTable) throws LODNetworkExceptionFinds the connected components and writes the node component relationship into component table. The caller needs to make sure that the component table already exists before calling this method.- Parameters:
networkName- network namelinkLevel- link levelcomponentTable- connected component table name- Throws:
LODNetworkException
-
findConnectedComponentsInPartition
public static int findConnectedComponentsInPartition(java.lang.String networkName, int linkLevel, int partitionId, int startComponentId, java.sql.Array[] nodeArray, java.sql.Array[] componentArray) throws LODNetworkExceptionFind the connected components within a partition, with all the external nodes and boundary links included. This method writes the node id - component id assignment information into the input array, and returns the maximum component ID that has been used so far.- Parameters:
networkName- name of the networklinkLevel- link level on which the connected component is computedpartitionId- ID of the partition in which the connected component is computedstartComponentId- start component ID to be used. All component IDs being assigned to the nodes in the partition must be no smaller than the start component ID.nodeArray- empty array where the result node IDs are written intocomponentArray- empty array where the result component IDs are written into- Returns:
- Throws:
LODNetworkException
-
getPartitionSize
public static long getPartitionSize(java.lang.String networkName, int partitionId, int linkLevel, boolean includeUserData, boolean includeSpatialData) throws LODNetworkException, java.lang.ExceptionReturns the approximated size of a network partition in bytes- Parameters:
networkName- network namepartitionId- partition IDlinkLevel- link levelincludeUserData- is user defined data included in the partitionincludeSpatialData- is spatial information included in the partition- Returns:
- partition size in bytes
- Throws:
LODNetworkExceptionjava.lang.Exception
-
-