Class SQLValidator
- java.lang.Object
-
- oracle.spatial.network.nfe.io.jdbc.SQLValidator
-
public class SQLValidator extends java.lang.ObjectGeneral validator for standard sql naming conventions.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static SQLValidatorgetInstance()Method to get an instance from SQLValidator (Singleton).java.lang.StringgetValidatedQuery(java.sql.Connection conn, java.lang.String wildCardedQuery, java.lang.String... sqlNames)Receives a wildCarded SQL query and a list of SQL Names as parameters of the wildCards.
-
-
-
Method Detail
-
getInstance
public static SQLValidator getInstance()
Method to get an instance from SQLValidator (Singleton).- Returns:
- SQLValidator instance.
-
getValidatedQuery
public java.lang.String getValidatedQuery(java.sql.Connection conn, java.lang.String wildCardedQuery, java.lang.String... sqlNames) throws NFEIOExceptionReceives a wildCarded SQL query and a list of SQL Names as parameters of the wildCards. Validates if all the sql Names are valid ones, and if so, replaces the wildCards and returns the complete query.- Parameters:
conn- Connection to the DatabasewildCardedQuery- Query with the wildCards in the form of :parametersqlNames- List of sql names- Returns:
- the completed query with all the validates sql names
- Throws:
NFEIOException- An exception listing the invalid names. Error Code:NFEIOException.INVALID_SQL_NAME.
-
-