You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by dj...@apache.org on 2006/03/29 18:36:21 UTC

svn commit: r389822 - in /db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc: EmbedPreparedStatement.java EmbedStatement.java

Author: djd
Date: Wed Mar 29 08:36:19 2006
New Revision: 389822

URL: http://svn.apache.org/viewcvs?rev=389822&view=rev
Log:
DERBY-1158 (partial) Some method protection cleanup on EmbedStatement and EmbedPreparedStatement

Modified:
    db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java
    db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java?rev=389822&r1=389821&r2=389822&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java Wed Mar 29 08:36:19 2006
@@ -815,7 +815,7 @@
   	  }
     }
 
-	protected boolean executeBatchElement(Object batchElement) throws SQLException, StandardException {
+	boolean executeBatchElement(Object batchElement) throws SQLException, StandardException {
 		
 		ParameterValueSet temp = (ParameterValueSet) batchElement;
 
@@ -1415,7 +1415,7 @@
 		}
 	}
 
-	protected boolean executeStatement(Activation a,
+	boolean executeStatement(Activation a,
                      boolean executeQuery, boolean executeUpdate)
                      throws SQLException {
 
@@ -1425,7 +1425,7 @@
 		return super.executeStatement(a, executeQuery, executeUpdate);
 	}
 
-	protected final SQLException dataTypeConversion(int column, String sourceType)
+	final SQLException dataTypeConversion(int column, String sourceType)
 		throws SQLException {
 		SQLException se = newSQLException(SQLState.LANG_DATA_TYPE_GET_MISMATCH, getEmbedParameterSetMetaData().getParameterTypeName(column),
 			sourceType);

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java?rev=389822&r1=389821&r2=389822&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/jdbc/EmbedStatement.java Wed Mar 29 08:36:19 2006
@@ -62,21 +62,21 @@
 
 	private final java.sql.Connection applicationConnection;
 
-	protected int updateCount = -1;
-	protected java.sql.ResultSet results;
+	int updateCount = -1;
+	java.sql.ResultSet results;
 	//for jdbc3.0 feature, where you can get a resultset of rows inserted
 	//for auto generated columns after an insert
 	private java.sql.ResultSet autoGeneratedKeysResultSet;
-	protected String cursorName;
+	private String cursorName;
 
-	protected final boolean forMetaData;
+	private final boolean forMetaData;
 	final int resultSetType;
 	private final int resultSetConcurrency;
 	private final int resultSetHoldability;
-	protected final LanguageConnectionContext lcc;
+	final LanguageConnectionContext lcc;
 
 	private SQLWarning warnings;
-	protected String SQLText;
+	String SQLText;
 
     private int fetchSize = 1;
     private int fetchDirection = JDBC20Translation.FETCH_FORWARD;
@@ -84,11 +84,11 @@
     private int timeoutSeconds;
 
 	//the state of this statement, set to false when close() is called
-	protected boolean active = true;
+	private boolean active = true;
 
     //in case of batch update, save the individual statements in the batch in this vector
  	//this is only used by JDBC 2.0
- 	protected Vector batchStatements;
+ 	Vector batchStatements;
 	
 	// The maximum # of rows to return per result set.
 	// (0 means no limit.)
@@ -223,7 +223,7 @@
  		throw Util.notImplemented("executeUpdate(String, String[])");
 	}
 
-	protected final void checkIfInMiddleOfBatch() throws SQLException {
+	final void checkIfInMiddleOfBatch() throws SQLException {
 		/* If batchStatements is not null then we are in the middle
 		 * of a batch. That's an invalid state. We need to finish the
 		 * batch either by clearing the batch or executing the batch.
@@ -524,7 +524,7 @@
      * @see #getMoreResults
 	 * @exception SQLException thrown on failure
      */
-	protected boolean execute(String sql, boolean executeQuery, boolean executeUpdate,
+	private boolean execute(String sql, boolean executeQuery, boolean executeUpdate,
 		int autoGeneratedKeys, int[] columnIndexes, String[] columnNames) throws SQLException
 	{
 
@@ -940,7 +940,7 @@
 	/**
 		Execute a single element of the batch. Overridden by EmbedPreparedStatement
 	*/
-	protected boolean executeBatchElement(Object batchElement) throws SQLException, StandardException {
+	boolean executeBatchElement(Object batchElement) throws SQLException, StandardException {
 		return execute((String)batchElement, false, true, JDBC30Translation.NO_GENERATED_KEYS, null, null);
 	}
 
@@ -1082,7 +1082,7 @@
 		Execute the current statement.
 	    @exception SQLException thrown on failure.
 	*/
-	protected boolean executeStatement(Activation a,
+	boolean executeStatement(Activation a,
                      boolean executeQuery, boolean executeUpdate)
                      throws SQLException {
 
@@ -1328,7 +1328,7 @@
 		Close and clear all result sets associated with this statement
 		from the last execution.
 	*/
-	protected void clearResultSets() throws SQLException {
+	void clearResultSets() throws SQLException {
 
 		SQLException sqle = null;
 
@@ -1390,7 +1390,7 @@
 	/**
 		Check to see if a statement requires to be executed via a callable statement.
 	*/
-	protected void checkRequiresCallableStatement(Activation activation) throws SQLException {
+	void checkRequiresCallableStatement(Activation activation) throws SQLException {
 
 		ParameterValueSet pvs = activation.getParameterValueSet();