Powered by SmartDoc

Relaxer Table View Object

Relaxer Table View Object (RTVO) is a Data Access Object (DAO) to read RDBMS tables. RTVO is different from RTO because RTVO does not have methods modifing contents of the table.

Basic Style

Table 14.3.1.1[Relaxer Table View Object method list] is a list of constructors for RTVO.

Relaxer Table View Object method list
Signature Function
Constructor(String url, String selectClause) Creates an RTVO from the JDBC URL and the select clause.
Constructor(String url, String selectClause, String username, String password) Creates an RTVO from the JDBC URL, the select clause, the user name, and the password.
Constructor(String url, String selectClause, java.util.Properties properties) Creates an RTVO from the JDBC URL, the select clause, and the properties.
Constructor(java.sql.Connection, String selectClause) Creates an RTVO from the SQL connection and the select clause.

Table 14.3.1.2[Relaxer Table View Object instance method list] is a list of instance methods for RTVO.

Relaxer Table View Object instance method list
Signature Function
boolean getJdbc2() Gets whether or not the JDBC2 facility is available.
void setJdbc2(boolean jdbc2) Sets whether or not JDBC2 facility is available.
String getQuoteId() Gets a quote symbol to quote ids in SQL.
void setQuoteId(String quoteId) Sets a quote symbol to quote ids in SQL.
String getQuoteWhere() Gets a quote symbol to quote a where clause in SQL.
void setQuoteWhere(String quoteWhere) Sets a quote symbol to quote a where clause in SQL.
String getQuoteIdInWhere() Gets a quote symbol to quote ids in a where clause in SQL.
void setQuoteIdInWhere(String quoteIdInWhere) Sets a quote symbol to quote ids in a where clause in SQL.
java.sql.Connection getConnection() Gets the JDBC connection.
String getSelectClause() Gets the select clause to be used in the RTO.
boolean getAutoCommit() Gets whether or not auto-commit is available.
void setAutoCommit(boolean autoCommit) Sets whether or not auto-commit is available.
void commit() Commits the transaction.
void rollback() Aborts the transaction.
boolean getTransactionIsolation() Gets the transaction isolation level.
void setTransactionIsolation(boolean transactionIsolation) Sets the transaction isolation level.
void dispose() Release the resources used by the RTO.
void close() Closes the RTO.
boolean isClosed() Tests whether or not the RTO is closed.
org.w3c.dom.Document[] selectAsDocuments() Selects all records as XML documents.
RelaxerObject[] select() Selects all records as ROs.
org.w3c.dom.Element[] selectAsElements(org.w3c.dom.Document doc) Selects all records as XML elements.
org.w3c.dom.Document selectAsDocument() Selects all records as an XML document.
org.w3c.dom.Document[] selectAsDocuments(String where) Selects all records specified by the where cluase as XML documents.
RelaxerObject[] select(String where) Selects all records specified by the where cluase as ROs.
org.w3c.dom.Element[] selectAsElements(org.w3c.dom.Document doc, String where) Selects all records specified by the where cluase as XML elements.
org.w3c.dom.Document selectAsDocument(String where) Selects all records specified by the where cluase as an XML element.
org.w3c.dom.Document[] selectByExpressionAsDocuments(String expression) Selects all records specified by the expression as XML documents.
RelaxerObject[] selectByExpression(String expression) Selects all records specified by the expression as ROs.
org.w3c.dom.Element[] selectByExpressionAsElements(org.w3c.dom.Document doc, String expression) Selects all records specified by the expression as XML elements.
org.w3c.dom.Document selectByExpressionAsDocument(String expression) Selects all records specified by the expression cluase as an XML element.
RelaxerTableListObject selectAsList() Selects all records as an RTLO.
RelaxerTableListObject selectAsList(String where) Selects all records specified by the where cluase as an RTLO.
RelaxerTableListObject selectByExpressionAsList(String expression) Selects all records specified by the expression as an RTLO.

Table 14.3.1.3[Relaxer Table View Object static method list] is a list of static mehotds for RTVO.

Relaxer Table View Object static method list
Signature Function
org.w3c.dom.Document[] makeDocuments(java.sql.ResultSet rs) Creates XML documents from the ResultSet.
org.w3c.dom.Document makeDocument(java.sql.ResultSet rs) Creates an XML document from the ResultSet.
org.w3c.dom.Element[] makeElements(java.sql.ResultSet rs, org.w3c.dom.Document doc) Creates XML elements from the ResultSet.
org.w3c.dom.Element makeElement(java.sql.ResultSet rs, org.w3c.dom.Document doc) Creates an XML elements from the ResultSet.

The jdbc.ee

If the jdbc.ee is set to true, a constructor shown below accept a JNDI name in addition to a normal JDBC URL.

sql:primary

Table 14.3.3.1[Relaxer Table Object static method list] is a list of static methods for RTO.

Relaxer Table Object static method list
Signature Function
org.w3c.dom.Document getByPropertyAsDocument(Type key) Gets a record specified by the key as an XML document.
Type getByProperty(Type key) Gets a record specified by the key as a RO.