db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d..@apache.org
Subject svn commit: r1478635 [4/5] - in /db/derby/code/trunk/java: client/org/apache/derby/client/ client/org/apache/derby/client/am/ client/org/apache/derby/client/net/ client/org/apache/derby/jdbc/ engine/org/apache/derby/iapi/services/info/ testing/org/apac...
Date Fri, 03 May 2013 03:42:16 GMT
Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionReply.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionReply.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionReply.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionReply.java Fri May  3 03:42:14 2013
@@ -21,7 +21,7 @@
 
 package org.apache.derby.client.net;
 
-import java.util.HashMap;
+import java.util.List;
 import javax.transaction.xa.Xid;
 
 import org.apache.derby.client.am.ClientConnection;
@@ -114,28 +114,28 @@ public class NetConnectionReply extends 
     }
 
 
-    protected void readXaStartUnitOfWork(NetConnection conn) throws DisconnectException {
+    void readXaStartUnitOfWork(NetConnection conn) throws DisconnectException {
     }
 
-    protected int readXaEndUnitOfWork(NetConnection conn) throws DisconnectException {
+    int readXaEndUnitOfWork(NetConnection conn) throws DisconnectException {
         return 0;
     }
 
-    protected int readXaPrepare(NetConnection conn) throws DisconnectException {
+    int readXaPrepare(NetConnection conn) throws DisconnectException {
         return 0;
     }
 
-    protected void readXaCommit(NetConnection conn) throws DisconnectException {
+    void readXaCommit(NetConnection conn) throws DisconnectException {
     }
 
-    protected int readXaRollback(NetConnection conn) throws DisconnectException {
+    int readXaRollback(NetConnection conn) throws DisconnectException {
         return 0;
     }
 
-    protected void readXaRecover(NetConnection conn) throws DisconnectException {
+    void readXaRecover(NetConnection conn) throws DisconnectException {
     }
 
-    protected void readXaForget(NetConnection conn) throws DisconnectException {
+    void readXaForget(NetConnection conn) throws DisconnectException {
     }
 
 
@@ -270,7 +270,7 @@ public class NetConnectionReply extends 
     }
 
 
-    protected int parseTypdefsOrMgrlvlovrs() throws DisconnectException {
+    int parseTypdefsOrMgrlvlovrs() throws DisconnectException {
         boolean targetTypedefCloned = false;
         while (true) {
             int peekCP = peekCodePoint();
@@ -295,7 +295,8 @@ public class NetConnectionReply extends 
 
     //-----------------------------parse DDM Reply Messages-----------------------
 
-    protected void parseCommitError(ConnectionCallbackInterface connection) throws DisconnectException {
+    private void parseCommitError(ConnectionCallbackInterface connection)
+            throws DisconnectException {
         int peekCP = peekCodePoint();
         switch (peekCP) {
         case CodePoint.ABNUOWRM:
@@ -314,7 +315,7 @@ public class NetConnectionReply extends 
         }
     }
 
-    void parseRollbackError() throws DisconnectException {
+    private void parseRollbackError() throws DisconnectException {
         int peekCP = peekCodePoint();
         switch (peekCP) {
         case CodePoint.CMDCHKRM:
@@ -360,7 +361,8 @@ public class NetConnectionReply extends 
         }
     }
 
-    void parseSecurityCheckError(NetConnection netConnection) throws DisconnectException {
+    private void parseSecurityCheckError(NetConnection netConnection)
+            throws DisconnectException {
         int peekCP = peekCodePoint();
         switch (peekCP) {
         case CodePoint.CMDCHKRM:
@@ -476,7 +478,8 @@ public class NetConnectionReply extends 
         return parseAbnormalEndUow(r.getConnectionCallbackInterface(),r);
     }
 
-    void parseRdbAccessFailed(NetConnection netConnection) throws DisconnectException {
+    private void parseRdbAccessFailed(NetConnection netConnection)
+            throws DisconnectException {
         parseRDBAFLRM();
 
         // an SQLCARD is returned if an RDBALFRM is returned.
@@ -792,7 +795,7 @@ public class NetConnectionReply extends 
     //   RECCNT - optional (MINVAL 0, MINLVL 3)
     //
     // Called by all the Reply classesCMDCHKRM
-    protected void parseCMDCHKRM() throws DisconnectException {
+    void parseCMDCHKRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;
@@ -1077,7 +1080,7 @@ public class NetConnectionReply extends 
     // CODPNT - optional (MINLVL 3)
     // RDBNAM - optional (MINLVL 3)
     //
-    protected void parseSYNTAXRM() throws DisconnectException {
+    private void parseSYNTAXRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean synerrcdReceived = false;
@@ -1335,7 +1338,7 @@ public class NetConnectionReply extends 
     // RECCNT - optional (MINLVL 3, MINVAL 0) (will not be returned - should be ignored)
     // RDBNAM - optional (MINLVL 3)
     //
-    protected void parseVALNSPRM() throws DisconnectException {
+    private void parseVALNSPRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;
@@ -1420,7 +1423,7 @@ public class NetConnectionReply extends 
     // RECCNT - optional (MINVAL 0, MINLVL 3)
     // RDBNAM - optional (NINLVL 3)
     //
-    protected void parsePRCCNVRM() throws DisconnectException {
+    private void parsePRCCNVRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;
@@ -1650,7 +1653,7 @@ public class NetConnectionReply extends 
     // CODPNT - required
     // RDBNAM - optional (MINLVL 3)
     //
-    protected void parseCMDNSPRM() throws DisconnectException {
+    void parseCMDNSPRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;
@@ -1782,7 +1785,6 @@ public class NetConnectionReply extends 
         boolean srvclsnmReceived = false;
         String srvclsnm = null;
         boolean srvnamReceived = false;
-        String srvnam = null;
         boolean srvrlslvReceived = false;
         String srvrlslv = null;
 
@@ -1836,7 +1838,7 @@ public class NetConnectionReply extends 
                 // for logging errors.
                 foundInPass = true;
                 srvnamReceived = checkAndGetReceivedFlag(srvnamReceived);
-                srvnam = parseSRVNAM();
+                parseSRVNAM(); // not used yet
                 peekCP = peekCodePoint();
             }
 
@@ -1859,7 +1861,7 @@ public class NetConnectionReply extends 
         }
         popCollectionStack();
         // according the the DDM book, all these instance variables are optional
-        netConnection.setServerAttributeData(srvclsnm, srvnam, srvrlslv);
+        netConnection.setServerAttributeData(srvclsnm, srvrlslv);
     }
 
     // Must make a version that does not change state in the associated connection
@@ -2038,14 +2040,12 @@ public class NetConnectionReply extends 
         }
     }
 
-    // Called by all the NET*Reply classes.
-    void parseTYPDEFNAM() throws DisconnectException {
+    private void parseTYPDEFNAM() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.TYPDEFNAM);
         netAgent_.targetTypdef_.setTypdefnam(readString());
     }
 
-    // Called by all the NET*Reply classes.
-    void parseTYPDEFOVR() throws DisconnectException {
+    private void parseTYPDEFOVR() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.TYPDEFOVR);
         pushLengthOnCollectionStack();
         int peekCP = peekCodePoint();
@@ -2090,18 +2090,18 @@ public class NetConnectionReply extends 
     }
 
     // Process XA return value
-    protected int parseXARETVAL() throws DisconnectException {
+    int parseXARETVAL() throws DisconnectException {
         return 0;
     }
 
     // Process XA return value
-    protected byte parseSYNCTYPE() throws DisconnectException {
+    byte parseSYNCTYPE() throws DisconnectException {
         return 0;
     }
 
     // This method handles the parsing of all command replies and reply data
     // for the SYNCCTL command.
-    protected int parseSYNCCTLreply(ConnectionCallbackInterface connection) 
+    int parseSYNCCTLreply(ConnectionCallbackInterface connection)
         throws DisconnectException {
         if (peekCodePoint() == CodePoint.PBSD) {
             parsePBSD();
@@ -2283,14 +2283,14 @@ public class NetConnectionReply extends 
     // creates or activates to run the DDM server.
     // No semantic meaning is assigned to external names in DDM.
     // External names are transmitted to aid in problem determination.
-    protected String parseEXTNAM() throws DisconnectException {
+    private String parseEXTNAM() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.EXTNAM);
         return readString();
     }
 
     // Server Class name specifies the name of a class of DDM servers.
     // Server class names are assigned for each product involved in PROTOCOL.
-    protected String parseSRVCLSNM() throws DisconnectException {
+    private String parseSRVCLSNM() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SRVCLSNM);
         return readString();
     }
@@ -2299,7 +2299,7 @@ public class NetConnectionReply extends 
     // No semantic meaning is assigned to server names in DDM,
     // but it is recommended that the server names are transmitted
     // for problem determination.
-    protected String parseSRVNAM() throws DisconnectException {
+    private String parseSRVNAM() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SRVNAM);
         return readString();
     }
@@ -2310,26 +2310,26 @@ public class NetConnectionReply extends 
     // SRVRLSLV should not be used in place of product-defined
     // extensions to carry information not related to the products
     // release level.
-    protected String parseSRVRLSLV() throws DisconnectException {
+    private String parseSRVRLSLV() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SRVRLSLV);
         return readString();
     }
 
     // Manager-Level Number Attribute Binary Integer Number specifies
     // the level of a defined DDM manager.
-    protected int parseMGRLVLN() throws DisconnectException {
+    private int parseMGRLVLN() throws DisconnectException {
         return readUnsignedShort();
     }
 
     // Security Mechanims.
-    protected int[] parseSECMEC() throws DisconnectException {
+    private int[] parseSECMEC() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SECMEC);
         return readUnsignedShortList();
     }
 
     // The Security Token Byte String is information provided and used
     // by the various security mechanisms.
-    protected byte[] parseSECTKN(boolean skip) throws DisconnectException {
+    private byte[] parseSECTKN(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SECTKN);
         if (skip) {
             skipBytes();
@@ -2341,7 +2341,7 @@ public class NetConnectionReply extends 
 
     // The Security Check Code String codifies the security information
     // and condition for the SECCHKRM.
-    protected int parseSECCHKCD() throws DisconnectException {
+    private int parseSECCHKCD() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SECCHKCD);
         int secchkcd = readUnsignedByte();
         if ((secchkcd < CodePoint.SECCHKCD_00) || (secchkcd > CodePoint.SECCHKCD_15)) {
@@ -2352,7 +2352,7 @@ public class NetConnectionReply extends 
 
     // Product specific Identifier specifies the product release level
     // of a DDM server.
-    protected String parsePRDID(boolean skip) throws DisconnectException {
+    private String parsePRDID(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.PRDID);
         if (skip) {
             skipBytes();
@@ -2363,7 +2363,7 @@ public class NetConnectionReply extends 
     }
 
     // The User Id specifies an end-user name.
-    protected String parseUSRID(boolean skip) throws DisconnectException {
+    private String parseUSRID(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.USRID);
         if (skip) {
             skipBytes();
@@ -2375,13 +2375,13 @@ public class NetConnectionReply extends 
     // Code Point Data Representation specifies the data representation
     // of a dictionary codepoint.  Code points are hexadecimal aliases for DDM
     // named terms.
-    protected int parseCODPNTDR() throws DisconnectException {
+    private int parseCODPNTDR() throws DisconnectException {
         return readUnsignedShort();
     }
 
     // Correlation Token specifies a token that is conveyed between source
     // and target servers for correlating the processing between servers.
-    protected byte[] parseCRRTKN(boolean skip) throws DisconnectException {
+    private byte[] parseCRRTKN(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.CRRTKN);
         if (skip) {
             skipBytes();
@@ -2392,7 +2392,7 @@ public class NetConnectionReply extends 
 
     // Unit of Work Disposition Scalar Object specifies the disposition of the
     // last unit of work.
-    protected int parseUOWDSP() throws DisconnectException {
+    private int parseUOWDSP() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.UOWDSP);
         int uowdsp = readUnsignedByte();
         if ((uowdsp != CodePoint.UOWDSP_COMMIT) && (uowdsp != CodePoint.UOWDSP_ROLLBACK)) {
@@ -2404,7 +2404,7 @@ public class NetConnectionReply extends 
 
     // Relational Database Name specifies the name of a relational
     // database of the server.  A server can have more than one RDB.
-    protected String parseRDBNAM(boolean skip) throws DisconnectException {
+    String parseRDBNAM(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.RDBNAM);
         if (skip) {
             skipBytes();
@@ -2415,16 +2415,16 @@ public class NetConnectionReply extends 
 
 
 
-    protected int parseXIDCNT() throws DisconnectException {
+    int parseXIDCNT() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.XIDCNT);
         return readUnsignedShort();
     }
 
-    protected Xid parseXID() throws DisconnectException {
+    Xid parseXID() throws DisconnectException {
         return null;
     }
 
-    protected HashMap<Xid, NetIndoubtTransaction> parseIndoubtList()
+    List<Xid> parseIndoubtList()
             throws DisconnectException {
         return null;
     }
@@ -2432,7 +2432,7 @@ public class NetConnectionReply extends 
 
     // Syntax Error Code String specifies the condition that caused termination
     // of data stream parsing.
-    protected int parseSYNERRCD() throws DisconnectException {
+    private int parseSYNERRCD() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SYNERRCD);
         int synerrcd = readUnsignedByte();
         if ((synerrcd < 0x01) || (synerrcd > 0x1D)) {
@@ -2442,14 +2442,14 @@ public class NetConnectionReply extends 
     }
 
     // The Code Point Data specifies a scalar value that is an architected code point.
-    protected int parseCODPNT() throws DisconnectException {
+    private int parseCODPNT() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.CODPNT);
         return parseCODPNTDR();
     }
 
     // Conversational Protocol Error Code specifies the condition
     // for which the PRCCNVRm was returned.
-    protected int parsePRCCNVCD() throws DisconnectException {
+    private int parsePRCCNVCD() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.PRCCNVCD);
         int prccnvcd = readUnsignedByte();
         if ((prccnvcd != 0x01) && (prccnvcd != 0x02) && (prccnvcd != 0x03) &&
@@ -2463,28 +2463,28 @@ public class NetConnectionReply extends 
 
     // CCSID for Single-Byte Characters specifies a coded character
     // set identifier for single-byte characters.
-    protected int parseCCSIDSBC() throws DisconnectException {
+    private int parseCCSIDSBC() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.CCSIDSBC);
         return readUnsignedShort();
     }
 
     // CCSID for Mixed-Byte Characters specifies a coded character
     // set identifier for mixed-byte characters.
-    protected int parseCCSIDMBC() throws DisconnectException {
+    private int parseCCSIDMBC() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.CCSIDMBC);
         return readUnsignedShort();
     }
 
     // CCSID for Double-Byte Characters specifies a coded character
     // set identifier for double-byte characters.
-    protected int parseCCSIDDBC() throws DisconnectException {
+    private int parseCCSIDDBC() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.CCSIDDBC);
         return readUnsignedShort();
     }
 
     // Severity Code is an indicator of the severity of a condition
     // detected during the execution of a command.
-    protected int parseSVRCOD(int minSvrcod, int maxSvrcod) throws DisconnectException {
+    int parseSVRCOD(int minSvrcod, int maxSvrcod) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SVRCOD);
 
         int svrcod = readUnsignedShort();
@@ -2505,7 +2505,8 @@ public class NetConnectionReply extends 
         return svrcod;
     }
 
-    protected int parseFastSVRCOD(int minSvrcod, int maxSvrcod) throws DisconnectException {
+    int parseFastSVRCOD(int minSvrcod, int maxSvrcod)
+            throws DisconnectException {
         matchCodePoint(CodePoint.SVRCOD);
 
         int svrcod = readFastUnsignedShort();
@@ -2526,7 +2527,7 @@ public class NetConnectionReply extends 
         return svrcod;
     }
 
-    protected NetSqlca parseSQLCARD(Sqlca[] rowsetSqlca) throws DisconnectException {
+    NetSqlca parseSQLCARD(Sqlca[] rowsetSqlca) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SQLCARD);
         int ddmLength = getDdmLength();
         ensureBLayerDataInBuffer(ddmLength);
@@ -2724,14 +2725,15 @@ public class NetConnectionReply extends 
     // this is duplicated in parseColumnMetaData, but different
     // DAGroup under NETColumnMetaData requires a lot more stuffs including
     // precsion, scale and other stuffs
-    protected String parseFastVCS() throws DisconnectException {
+    String parseFastVCS() throws DisconnectException {
         // doublecheck what readString() does if the length is 0
         return readFastString(readFastUnsignedShort(),
                 netAgent_.targetTypdef_.getCcsidSbcEncoding());
     }
     //----------------------non-parsing computational helper methods--------------
 
-    protected boolean checkAndGetReceivedFlag(boolean receivedFlag) throws DisconnectException {
+    boolean checkAndGetReceivedFlag(boolean receivedFlag)
+            throws DisconnectException {
         if (receivedFlag) {
             // this method will throw a disconnect exception if
             // the received flag is already true;
@@ -2740,20 +2742,20 @@ public class NetConnectionReply extends 
         return true;
     }
 
-    protected void checkRequiredObjects(boolean receivedFlag) throws DisconnectException {
+    void checkRequiredObjects(boolean receivedFlag) throws DisconnectException {
         if (!receivedFlag) {
             doSyntaxrmSemantics(CodePoint.SYNERRCD_REQ_OBJ_NOT_FOUND);
         }
     }
 
-    protected void checkRequiredObjects(boolean receivedFlag,
+    void checkRequiredObjects(boolean receivedFlag,
                                         boolean receivedFlag2) throws DisconnectException {
         if (!receivedFlag || !receivedFlag2) {
             doSyntaxrmSemantics(CodePoint.SYNERRCD_REQ_OBJ_NOT_FOUND);
         }
     }
 
-    protected void checkRequiredObjects(boolean receivedFlag,
+    void checkRequiredObjects(boolean receivedFlag,
                                         boolean receivedFlag2,
                                         boolean receivedFlag3) throws DisconnectException {
         if (!receivedFlag || !receivedFlag2 || !receivedFlag3) {
@@ -2761,7 +2763,7 @@ public class NetConnectionReply extends 
         }
     }
 
-    protected void checkRequiredObjects(boolean receivedFlag,
+    private void checkRequiredObjects(boolean receivedFlag,
                                         boolean receivedFlag2,
                                         boolean receivedFlag3,
                                         boolean receivedFlag4) throws DisconnectException {
@@ -2774,14 +2776,14 @@ public class NetConnectionReply extends 
     // but means that these methods are private to this class and to subclasses,
     // and should not be used as package-wide friendly methods.
 
-    protected void doObjnsprmSemantics(int codePoint) throws DisconnectException {
+    private void doObjnsprmSemantics(int codePoint) throws DisconnectException {
         agent_.accumulateChainBreakingReadExceptionAndThrow(new DisconnectException(agent_,
             new ClientMessageId(SQLState.DRDA_DDM_OBJECT_NOT_SUPPORTED),
             Integer.toHexString(codePoint)));
     }
 
-    // Also called by NetStatementReply.
-    protected void doPrmnsprmSemantics(int codePoint) throws DisconnectException {
+    // Also called by NetStatementReply and others
+    void doPrmnsprmSemantics(int codePoint) throws DisconnectException {
         agent_.accumulateChainBreakingReadExceptionAndThrow(new DisconnectException(agent_,
             new ClientMessageId(SQLState.DRDA_DDM_PARAM_NOT_SUPPORTED),
             Integer.toHexString(codePoint)));
@@ -2936,7 +2938,8 @@ public class NetConnectionReply extends 
     //      The command or statement cannot be processed.  The current
     //          transaction is rolled back and the application is disconnected
     //          from the remote database.
-    protected void doPrccnvrmSemantics(int conversationProtocolErrorCode) throws DisconnectException {
+    private void doPrccnvrmSemantics(int conversationProtocolErrorCode)
+            throws DisconnectException {
         // we may need to map the conversation protocol error code, prccnvcd, to some kind
         // of reason code.  For now just return the prccnvcd as the reason code
         agent_.accumulateChainBreakingReadExceptionAndThrow(new DisconnectException(agent_,
@@ -2948,7 +2951,7 @@ public class NetConnectionReply extends 
     // SQL Diagnostics Condition Token Array - Identity 0xF7
     // SQLNUMROW; ROW LID 0x68; ELEMENT TAKEN 0(all); REP FACTOR 1
     // SQLTOKROW; ROW LID 0xE7; ELEMENT TAKEN 0(all); REP FACTOR 0(all)
-    void parseSQLDCTOKS() throws DisconnectException {
+    private void parseSQLDCTOKS() throws DisconnectException {
         if (readFastUnsignedByte() == CodePoint.NULLDATA) {
             return;
         }
@@ -3246,7 +3249,7 @@ public class NetConnectionReply extends 
         }
     }
 
-    void resetRowsetSqlca(Sqlca[] rowsetSqlca, int row) {
+    private void resetRowsetSqlca(Sqlca[] rowsetSqlca, int row) {
         // rowsetSqlca can be null.
         int count = ((rowsetSqlca == null) ? 0 : rowsetSqlca.length);
         for (int i = row; i < count; i++) {
@@ -3263,7 +3266,7 @@ public class NetConnectionReply extends 
      *
      * @throws org.apache.derby.client.am.DisconnectException
      */
-    protected void parseInitialPBSD(ClientConnection connection)
+    private void parseInitialPBSD(ClientConnection connection)
             throws DisconnectException {
         if (peekCodePoint() != CodePoint.PBSD) {
             return;
@@ -3296,7 +3299,7 @@ public class NetConnectionReply extends 
      * current schema as an UTF-8 String.
      * @throws org.apache.derby.client.am.DisconnectException
      */
-    protected void parsePBSD() throws DisconnectException {
+    void parsePBSD() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.PBSD);
         int peekCP = peekCodePoint();
         while (peekCP != END_OF_SAME_ID_CHAIN) {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionRequest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionRequest.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionRequest.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnectionRequest.java Fri May  3 03:42:14 2013
@@ -28,7 +28,9 @@ import org.apache.derby.client.am.SqlExc
 import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
-public class NetConnectionRequest extends Request implements ConnectionRequestInterface {
+class NetConnectionRequest extends Request
+    implements ConnectionRequestInterface {
+
     NetConnectionRequest(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
@@ -62,12 +64,6 @@ public class NetConnectionRequest extend
 
     }
 
-    void writeDummyExchangeServerAttributes() throws SqlException {
-        // send the exchange server attributes command to the server,
-        // without any parameters
-        buildDummyEXCSAT();
-    }
-
     void writeAccessSecurity(int securityMechanism,
                              String databaseName,
                              byte[] publicKey) throws SqlException {
@@ -191,7 +187,7 @@ public class NetConnectionRequest extend
     // The Relational Database Name (RDBNAM) is an optional parameter
     // which will not be sent by this command to reduce size, building,
     // and parsing.
-    void buildRDBRLLBCK() throws SqlException {
+    private void buildRDBRLLBCK() throws SqlException {
         createCommand();
         writeLengthCodePoint(0x04, CodePoint.RDBRLLBCK);
     }
@@ -203,7 +199,7 @@ public class NetConnectionRequest extend
     // - this driver's product release level
     // - this driver's external name
     // - this driver's server name
-    void buildEXCSAT(String externalName,
+    private void buildEXCSAT(String externalName,
                      int targetAgent,
                      int targetSqlam,
                      int targetRdb,
@@ -264,7 +260,7 @@ public class NetConnectionRequest extend
         updateLengthBytes();
     }
 
-    void buildDummyEXCSAT() throws SqlException {
+    private void buildDummyEXCSAT() throws SqlException {
         createCommand();
 
         // begin excsat collection by placing the 4 byte llcp in the buffer.
@@ -278,7 +274,7 @@ public class NetConnectionRequest extend
         updateLengthBytes();
     }
 
-    void buildACCSEC(int secmec,
+    private void buildACCSEC(int secmec,
                      String rdbnam,
                      byte[] sectkn) throws SqlException {
         createCommand();
@@ -307,7 +303,7 @@ public class NetConnectionRequest extend
         updateLengthBytes();
     }
 
-    void buildSECCHK(int secmec,
+    private void buildSECCHK(int secmec,
                      String rdbnam,
                      String user,
                      String password,
@@ -345,7 +341,7 @@ public class NetConnectionRequest extend
     // manager.  The access RDB command then binds the created instance to the target
     // agent and to the RDB. The RDB remains available (accessed) until
     // the communications conversation is terminate.
-    void buildACCRDB(String rdbnam,
+    private void buildACCRDB(String rdbnam,
                      boolean readOnly,
                      byte[] crrtkn,
                      byte[] prddta,
@@ -555,7 +551,7 @@ public class NetConnectionRequest extend
         writeScalarString(CodePoint.TYPDEFNAM, typdefnam);
     }
 
-    void buildTYPDEFOVR(boolean sendCcsidSbc,
+    private void buildTYPDEFOVR(boolean sendCcsidSbc,
                         int ccsidSbc,
                         boolean sendCcsidDbc,
                         int ccsidDbc,

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetCursor.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetCursor.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetCursor.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetCursor.java Fri May  3 03:42:14 2013
@@ -43,18 +43,13 @@ import org.apache.derby.client.am.Utils;
 import org.apache.derby.shared.common.reference.SQLState;
 import org.apache.derby.shared.common.sanity.SanityManager;
 
-public class NetCursor extends Cursor {
+class NetCursor extends Cursor {
 
     NetResultSet netResultSet_;
-    NetAgent netAgent_;
+    private NetAgent netAgent_;
 
     Typdef qrydscTypdef_;
 
-    int targetSqlamForTypdef_;
-
-
-    // override column meta data
-    int numMddOverrides_;
     int maximumRowSize_;
     boolean blocking_;  // if true, multiple rows may be "blocked" in a single reply
 
@@ -85,7 +80,6 @@ public class NetCursor extends Cursor {
     NetCursor(NetAgent netAgent) {
         super(netAgent);
         netAgent_ = netAgent;
-        numMddOverrides_ = 0;
         maximumRowSize_ = 0;
         extdtaPositions_ = new HashMap<Integer, Integer>();
         extdtaData_ = new ArrayList<byte[]>();
@@ -535,7 +529,7 @@ public class NetCursor extends Cursor {
     }
 
     // prereq: the base data for the cursor has been processed for offsets and lengths
-    boolean isNonTrivialDataLob(int index) {
+    private boolean isNonTrivialDataLob(int index) {
         long length = 0L;
 
         if (isNull_[index] ||
@@ -581,7 +575,7 @@ public class NetCursor extends Cursor {
     //
     // FORMAT FOR ALL SQLAM LEVELS
     //   SQLCAGRP; GROUP LID 0x54; ELEMENT TAKEN 0(all); REP FACTOR 1
-    NetSqlca[] parseSQLCARD(Typdef typdef)
+    private NetSqlca[] parseSQLCARD(Typdef typdef)
             throws DisconnectException, SqlException {
 
         return parseSQLCAGRP(typdef);
@@ -839,7 +833,7 @@ public class NetCursor extends Cursor {
     
     // SQL Diagnostics Condition Token Array - Identity 0xF7
     // NULLDATA will be received for now
-    void parseSQLDCTOKS() throws DisconnectException, SqlException {
+    private void parseSQLDCTOKS() throws DisconnectException, SqlException {
         if (readFdocaOneByte() == CodePoint.NULLDATA) {
             return;
         }
@@ -900,7 +894,7 @@ public class NetCursor extends Cursor {
         isNull_ = new boolean[columns_];
     }
 
-    protected byte[] findExtdtaData(int column) {
+    private byte[] findExtdtaData(int column) {
         byte[] data = null;
 
         // locate the EXTDTA bytes, if any
@@ -1028,8 +1022,10 @@ public class NetCursor extends Cursor {
     }
 
     // this is really an event-callback from NetStatementReply.parseSQLDTARDarray()
-    void initializeColumnInfoArrays(Typdef typdef,
-                                    int columnCount, int targetSqlamForTypdef) throws DisconnectException {
+    void initializeColumnInfoArrays(
+            Typdef typdef,
+            int columnCount) throws DisconnectException {
+
         qrydscTypdef_ = typdef;
 
         // Allocate  arrays to hold the descriptor information.
@@ -1037,7 +1033,6 @@ public class NetCursor extends Cursor {
         fdocaLength_ = new int[columnCount];
         isGraphic_ = new boolean[columnCount];
         typeToUseForComputingDataLength_ = new int[columnCount];
-        targetSqlamForTypdef_ = targetSqlamForTypdef;
     }
 
     protected void getMoreData_() throws SqlException {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData.java Fri May  3 03:42:14 2013
@@ -25,9 +25,9 @@ import org.apache.derby.client.am.Client
 import org.apache.derby.client.am.ProductLevel;
 import org.apache.derby.client.am.SqlException;
 
-public class NetDatabaseMetaData extends ClientDatabaseMetaData {
+class NetDatabaseMetaData extends ClientDatabaseMetaData {
 
-    public NetDatabaseMetaData(NetAgent netAgent, NetConnection netConnection) {
+    NetDatabaseMetaData(NetAgent netAgent, NetConnection netConnection) {
         // Consider setting product level during parse
         super(netAgent, netConnection, new ProductLevel(netConnection.productID_,
                 netConnection.targetSrvclsnm_,

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java Fri May  3 03:42:14 2013
@@ -27,10 +27,10 @@ import org.apache.derby.client.am.Client
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.shared.common.reference.SQLState;
 
-public class NetDatabaseMetaData40 extends NetDatabaseMetaData {
+class NetDatabaseMetaData40 extends NetDatabaseMetaData {
     
     
-    public NetDatabaseMetaData40(NetAgent netAgent, NetConnection netConnection) {
+    NetDatabaseMetaData40(NetAgent netAgent, NetConnection netConnection) {
         super(netAgent,netConnection);
     }
 

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetLogWriter.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetLogWriter.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetLogWriter.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetLogWriter.java Fri May  3 03:42:14 2013
@@ -35,11 +35,11 @@ public class NetLogWriter extends LogWri
 
     // The recevie constant is used to indicate that the bytes were read to a Stream.
     // It indicates to this class that a receive header should be used.
-    public static final int TYPE_TRACE_RECEIVE = 2;
+    static final int TYPE_TRACE_RECEIVE = 2;
 
     // The send constant is used to indicate that the bytes were written to
     // a Stream.  It indicates to this class that a send header should be used.
-    public static final int TYPE_TRACE_SEND = 1;
+    static final int TYPE_TRACE_SEND = 1;
 
     //------------------------------ internal constants --------------------------
 
@@ -190,7 +190,7 @@ public class NetLogWriter extends LogWri
     // The type is needed to indicate if the data is part of the send or receive buffer.
     // The class name, method name, and trcPt number are also written to the trace.
     // Not much checking is performed on the parameters.  This is done to help performance.
-    synchronized public void traceProtocolFlow(byte[] buff,
+    synchronized void traceProtocolFlow(byte[] buff,
                                                int offset,
                                                int len,
                                                int type,

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageReply.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageReply.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageReply.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageReply.java Fri May  3 03:42:14 2013
@@ -25,7 +25,7 @@ import org.apache.derby.client.am.Discon
 import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
-public class NetPackageReply extends NetConnectionReply {
+class NetPackageReply extends NetConnectionReply {
     NetPackageReply(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
@@ -153,7 +153,7 @@ public class NetPackageReply extends Net
     // RDBNAM - optional
     //
     // Also called by NetResultSetReply and NetStatementReply
-    void parseSQLERRRM() throws DisconnectException {
+    private void parseSQLERRRM() throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageRequest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageRequest.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageRequest.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPackageRequest.java Fri May  3 03:42:14 2013
@@ -27,8 +27,8 @@ import org.apache.derby.client.am.Client
 import org.apache.derby.shared.common.reference.SQLState;
 
 
-public class NetPackageRequest extends NetConnectionRequest {
-    static final String COLLECTIONNAME = "NULLID";
+class NetPackageRequest extends NetConnectionRequest {
+    private static final String COLLECTIONNAME = "NULLID";
 
     NetPackageRequest(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
@@ -43,7 +43,7 @@ public class NetPackageRequest extends N
     // variable which follows.
     static final String collectionName = "NULLID";
 
-    void buildCommonPKGNAMinfo(Section section) throws SqlException {
+    private void buildCommonPKGNAMinfo(Section section) throws SqlException {
         String collectionToFlow = COLLECTIONNAME;
         // the scalar data length field may or may not be required.  it depends
         // on the level of support and length of the data.
@@ -262,7 +262,7 @@ public class NetPackageRequest extends N
     }
 
 
-    public void encryptDataStream(int lengthLocation) throws SqlException {
+    void encryptDataStream(int lengthLocation) throws SqlException {
         byte[] clearedBytes = new byte[buffer.position() - lengthLocation];
         buffer.position(lengthLocation);
         buffer.get(clearedBytes);

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPreparedStatement.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPreparedStatement.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPreparedStatement.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetPreparedStatement.java Fri May  3 03:42:14 2013
@@ -29,7 +29,7 @@ import org.apache.derby.client.ClientPoo
 import org.apache.derby.client.am.MaterialPreparedStatement;
 
 
-public class NetPreparedStatement extends NetStatement
+class NetPreparedStatement extends NetStatement
         implements MaterialPreparedStatement {
 
     // Alias for (NetPreparedStatement) super.statement.

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet.java Fri May  3 03:42:14 2013
@@ -28,7 +28,8 @@ import org.apache.derby.client.am.Sectio
 import org.apache.derby.client.am.SqlException;
 
 
-public class NetResultSet extends ClientResultSet {
+
+class NetResultSet extends ClientResultSet {
     // Alias for (NetConnection) super.statement.connection
     private final NetConnection netConnection_;
 
@@ -48,7 +49,7 @@ public class NetResultSet extends Client
     //-----------------------------state------------------------------------------
 
     // This is used to avoid sending multiple outovr over subsequent next()'s
-    public boolean firstOutovrBuilt_ = false;
+    boolean firstOutovrBuilt_ = false;
 
     //---------------------constructors/finalizer---------------------------------
 
@@ -122,7 +123,6 @@ public class NetResultSet extends Client
         }
 
         queryInstanceIdentifier_ = qryinsid;
-        nestingLevel_ = (int) ((queryInstanceIdentifier_ >>> 48) & 0xFFFF);
     }
 
 
@@ -187,9 +187,6 @@ public class NetResultSet extends Client
         }
     }
 
-    void queryDataWasReturnedOnOpen() throws DisconnectException {
-    }
-
     // ------------------------------- abstract box car methods --------------------------------------
     public void writeFetch_(Section section) throws SqlException {
         if (resultSetType_ == ResultSet.TYPE_FORWARD_ONLY && fetchSize_ != 0 &&
@@ -262,4 +259,19 @@ public class NetResultSet extends Client
             netCursor_.scanDataBufferForEndOfData();
         }
     }
+
+    // Analyze the error handling here, and whether or not can be pushed to
+    // common can we make this the common layer fetch method.  Called by the
+    // read/skip Fdoca bytes methods in the net whenever data reads exhaust the
+    // internal buffer used by this reply.
+    void flowFetch() throws DisconnectException, SqlException {
+        agent_.beginWriteChain(statement_);
+        writeFetch_((generatedSection_ == null) ?
+                statement_.section_ :
+                generatedSection_);
+        agent_.flow(statement_);
+        readFetch_();
+        agent_.endReadChain();
+    }
+
 }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet42.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet42.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet42.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet42.java Fri May  3 03:42:14 2013
@@ -24,13 +24,11 @@ package org.apache.derby.client.net;
 import java.sql.SQLException;
 import java.sql.SQLType;
 import org.apache.derby.client.am.Cursor;
-import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.client.am.Utils42;
-import org.apache.derby.shared.common.reference.SQLState;
 
 
-public class NetResultSet42 extends NetResultSet40
+class NetResultSet42 extends NetResultSet40
 {
     
     NetResultSet42(NetAgent netAgent,

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetReply.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetReply.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetReply.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetReply.java Fri May  3 03:42:14 2013
@@ -30,8 +30,10 @@ import org.apache.derby.client.am.Client
 import org.apache.derby.shared.common.reference.SQLState;
 import org.apache.derby.shared.common.reference.MessageId;
 
-public class NetResultSetReply extends NetStatementReply implements ResultSetReplyInterface {
-    public NetResultSetReply(NetAgent netAgent, int bufferSize) {
+class NetResultSetReply extends NetStatementReply
+    implements ResultSetReplyInterface {
+
+    NetResultSetReply(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
 
@@ -202,7 +204,9 @@ public class NetResultSetReply extends N
         }
     }
 
-    void parseCloseError(ResultSetCallbackInterface resultSetI) throws DisconnectException {
+    private void parseCloseError(ResultSetCallbackInterface resultSetI)
+            throws DisconnectException {
+
         int peekCP = peekCodePoint();
         switch (peekCP) {
         case CodePoint.ABNUOWRM:
@@ -228,7 +232,9 @@ public class NetResultSetReply extends N
         }
     }
 
-    void parseFetchError(ResultSetCallbackInterface resultSetI) throws DisconnectException {
+    private void parseFetchError(ResultSetCallbackInterface resultSetI)
+            throws DisconnectException {
+
         int peekCP = peekCodePoint();
         switch (peekCP) {
         case CodePoint.ABNUOWRM:

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetRequest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetRequest.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetRequest.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSetRequest.java Fri May  3 03:42:14 2013
@@ -30,9 +30,10 @@ import org.apache.derby.client.am.Client
 
 import org.apache.derby.shared.common.reference.SQLState;
 
-public class NetResultSetRequest extends NetStatementRequest
+class NetResultSetRequest extends NetStatementRequest
         implements ResultSetRequestInterface {
-    public NetResultSetRequest(NetAgent netAgent, int bufferSize) {
+
+    NetResultSetRequest(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
 

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqlca.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqlca.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqlca.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqlca.java Fri May  3 03:42:14 2013
@@ -29,7 +29,7 @@ import java.io.UnsupportedEncodingExcept
 import org.apache.derby.client.am.ClientConnection;
 import org.apache.derby.client.am.DisconnectException;
 
-public class NetSqlca extends Sqlca {
+class NetSqlca extends Sqlca {
     // these are the same variables that are in the Sqlca except ccsids
     // are a little different
 

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqldta.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqldta.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqldta.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetSqldta.java Fri May  3 03:42:14 2013
@@ -24,13 +24,10 @@ package org.apache.derby.client.net;
 import org.apache.derby.client.am.SqlException;
 
 
-public class NetSqldta extends NetCursor {
-    private NetConnection netConnection_;
+class NetSqldta extends NetCursor {
 
-
-    public NetSqldta(NetAgent netAgent) {
+    NetSqldta(NetAgent netAgent) {
         super(netAgent);
-        netConnection_ = netAgent.netConnection_;
     }
 
     public boolean next() throws SqlException {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatement.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatement.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatement.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatement.java Fri May  3 03:42:14 2013
@@ -29,7 +29,7 @@ import org.apache.derby.client.am.Client
 import org.apache.derby.client.am.MaterialStatement;
 import org.apache.derby.jdbc.ClientDriver;
 
-public class NetStatement implements MaterialStatement {
+class NetStatement implements MaterialStatement {
 
     ClientStatement statement_;
 
@@ -42,7 +42,7 @@ public class NetStatement implements Mat
 
 
     // If qryrowset is sent on opnqry then it also needs to be sent on every subsequent cntqry.
-    public boolean qryrowsetSentOnOpnqry_ = false;
+    boolean qryrowsetSentOnOpnqry_ = false;
 
     //---------------------constructors/finalizer---------------------------------
 
@@ -88,18 +88,6 @@ public class NetStatement implements Mat
         statement_.setMaterialStatement(this);
     }
 
-    // Called by abstract Connection.createStatement().newStatement() for jdbc 1 statements
-    NetStatement(NetAgent netAgent, NetConnection netConnection) throws SqlException {
-        this(ClientDriver.getFactory().newStatement(netAgent, netConnection),
-                netAgent,
-                netConnection);
-    }
-
-    void netReset(NetAgent netAgent, NetConnection netConnection) throws SqlException {
-        statement_.resetStatement(netAgent, netConnection);
-        resetNetStatement(statement_, netAgent, netConnection);
-    }
-
     public void reset_() {
         qryrowsetSentOnOpnqry_ = false;
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementReply.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementReply.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementReply.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementReply.java Fri May  3 03:42:14 2013
@@ -40,7 +40,9 @@ import org.apache.derby.shared.common.i1
 import org.apache.derby.shared.common.reference.MessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
-public class NetStatementReply extends NetPackageReply implements StatementReplyInterface {
+class NetStatementReply extends NetPackageReply
+    implements StatementReplyInterface {
+
     NetStatementReply(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
@@ -357,7 +359,8 @@ public class NetStatementReply extends N
         }
     }
 
-    protected void parseResultSetProcedure(StatementCallbackInterface statementI) throws DisconnectException {
+    private void parseResultSetProcedure(StatementCallbackInterface statementI)
+            throws DisconnectException {
         // when a stored procedure is called which returns result sets,
         // the next thing to be returned after the optional transaction component
         // is the summary component.
@@ -426,7 +429,7 @@ public class NetStatementReply extends N
     // followed by an optional SQLCARD, followed by an optional
     // SQL Column Information Reply data object, followed by a Query Descriptor.
     // There may also be Query Data or an End of Query Reply Message.
-    protected NetResultSet parseResultSetCursor(StatementCallbackInterface statementI,
+    NetResultSet parseResultSetCursor(StatementCallbackInterface statementI,
                                                 Section section) throws DisconnectException {
         // The first item returne is an OPNQRYRM.
         NetResultSet netResultSet = parseOPNQRYRM(statementI, false);
@@ -470,7 +473,8 @@ public class NetStatementReply extends N
         return netResultSet;
     }
 
-    protected void parseOpenQuery(StatementCallbackInterface statementI) throws DisconnectException {
+    void parseOpenQuery(StatementCallbackInterface statementI)
+            throws DisconnectException {
         NetResultSet netResultSet = parseOPNQRYRM(statementI, true);
 
         NetSqlca sqlca = null;
@@ -527,7 +531,8 @@ public class NetStatementReply extends N
         statementI.completeOpenQuery(sqlca, netResultSet);
     }
 
-    protected void parseEndQuery(ResultSetCallbackInterface resultSetI) throws DisconnectException {
+    void parseEndQuery(ResultSetCallbackInterface resultSetI)
+            throws DisconnectException {
         parseENDQRYRM(resultSetI);
         parseTypdefsOrMgrlvlovrs();
         NetSqlca netSqlca = parseSQLCARD(null);
@@ -766,7 +771,7 @@ public class NetStatementReply extends N
      * @return a <code>NetResultSet</code> value
      * @exception DisconnectException
      */
-    protected NetResultSet parseOPNQRYRM(StatementCallbackInterface statementI,
+    NetResultSet parseOPNQRYRM(StatementCallbackInterface statementI,
                                          boolean isOPNQRYreply)
         throws DisconnectException
     {
@@ -952,7 +957,8 @@ public class NetStatementReply extends N
     // terminated in such a manner that the query or result set is now closed.
     // It cannot be resumed with the CNTQRY command or closed with the CLSQRY command.
     // The ENDQRYRM is always followed by an SQLCARD.
-    protected void parseENDQRYRM(ResultSetCallbackInterface resultSetI) throws DisconnectException {
+    void parseENDQRYRM(ResultSetCallbackInterface resultSetI)
+            throws DisconnectException {
         boolean svrcodReceived = false;
         int svrcod = CodePoint.SVRCOD_INFO;
         boolean rdbnamReceived = false;
@@ -1194,7 +1200,7 @@ public class NetStatementReply extends N
     // Returned from Server:
     //   FDODSC - required
     //   FDODTA - required
-    protected NetSqlca parseSQLDTARD(NetSqldta netSqldta) throws DisconnectException {
+    NetSqlca parseSQLDTARD(NetSqldta netSqldta) throws DisconnectException {
         boolean fdodscReceived = false;
         boolean fdodtaReceived = false;
 
@@ -1232,7 +1238,7 @@ public class NetStatementReply extends N
         return netSqlca;
     }
 
-    protected void parseQRYDSC(NetCursor cursor) throws DisconnectException {
+    void parseQRYDSC(NetCursor cursor) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.QRYDSC);
         parseSQLDTARDarray(cursor, false); // false means don't just skip the bytes
     }
@@ -1299,7 +1305,8 @@ public class NetStatementReply extends N
                 // i.e. from integer to char.
                 int columns = peekTotalColumnCount(tripletLength);
                 // peek ahead to get the total number of columns.
-                cursor.initializeColumnInfoArrays(netAgent_.targetTypdef_, columns, netAgent_.targetSqlam_);
+                cursor.initializeColumnInfoArrays(
+                    netAgent_.targetTypdef_, columns);
                 columnCount += parseSQLDTAGRPdataLabelsAndUpdateColumn(cursor, columnCount, tripletLength);
                 break;
 
@@ -1452,7 +1459,7 @@ public class NetStatementReply extends N
                 (Object [])null)));
     }
 
-    protected void parseQRYDTA(NetResultSet netResultSet) throws DisconnectException {
+    void parseQRYDTA(NetResultSet netResultSet) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.QRYDTA);
         if (longValueForDecryption_ == null) {
             int ddmLength = getDdmLength();
@@ -1519,7 +1526,7 @@ public class NetStatementReply extends N
         netCursor.lastValidBytePosition_ = netCursor.dataBuffer_.length;
     }
 
-    protected void copyEXTDTA(NetCursor netCursor) throws DisconnectException {
+    void copyEXTDTA(NetCursor netCursor) throws DisconnectException {
         try {
             parseLengthAndMatchCodePoint(CodePoint.EXTDTA);
             byte[] data = null;
@@ -1546,7 +1553,7 @@ public class NetStatementReply extends N
     //
     // Only called for generated secctions from a callable statement.
     //
-    protected Section parsePKGNAMCSN(boolean skip) throws DisconnectException {
+    Section parsePKGNAMCSN(boolean skip) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.PKGNAMCSN);
         if (skip) {
             skipBytes();
@@ -1649,7 +1656,7 @@ public class NetStatementReply extends N
         return section;
     }
 
-    protected int parseFastQRYPRCTYP() throws DisconnectException {
+    int parseFastQRYPRCTYP() throws DisconnectException {
         matchCodePoint(CodePoint.QRYPRCTYP);
         int qryprctyp = readFastUnsignedShort();
         if ((qryprctyp != CodePoint.FIXROWPRC) && (qryprctyp != CodePoint.LMTBLKPRC)) {
@@ -1658,7 +1665,7 @@ public class NetStatementReply extends N
         return qryprctyp;
     }
 
-    protected int parseFastSQLCSRHLD() throws DisconnectException {
+    int parseFastSQLCSRHLD() throws DisconnectException {
         matchCodePoint(CodePoint.SQLCSRHLD);
         int sqlcsrhld = readFastUnsignedByte();
         // 0xF0 is false (default), 0xF1 is true  // use constants in if
@@ -1668,7 +1675,7 @@ public class NetStatementReply extends N
         return sqlcsrhld;
     }
 
-    protected int parseFastQRYATTSCR() throws DisconnectException {
+    int parseFastQRYATTSCR() throws DisconnectException {
         matchCodePoint(CodePoint.QRYATTSCR);
         int qryattscr = readFastUnsignedByte();  // use constants in if
         if ((qryattscr != 0xF0) && (qryattscr != 0xF1)) {
@@ -1677,7 +1684,7 @@ public class NetStatementReply extends N
         return qryattscr;
     }
 
-    protected int parseFastQRYATTSET() throws DisconnectException {
+    int parseFastQRYATTSET() throws DisconnectException {
         matchCodePoint(CodePoint.QRYATTSET);
         int qryattset = readFastUnsignedByte();  // use constants in if
         if ((qryattset != 0xF0) && (qryattset != 0xF1)) {
@@ -1686,7 +1693,7 @@ public class NetStatementReply extends N
         return qryattset;
     }
 
-    protected int parseFastQRYATTSNS() throws DisconnectException {
+    int parseFastQRYATTSNS() throws DisconnectException {
         matchCodePoint(CodePoint.QRYATTSNS);
         int qryattsns = readFastUnsignedByte();
         switch (qryattsns) {
@@ -1701,7 +1708,7 @@ public class NetStatementReply extends N
         return qryattsns;
     }
 
-    protected int parseFastQRYATTUPD() throws DisconnectException {
+    int parseFastQRYATTUPD() throws DisconnectException {
         matchCodePoint(CodePoint.QRYATTUPD);
         int qryattupd = readFastUnsignedByte();
         switch (qryattupd) {
@@ -1738,7 +1745,7 @@ public class NetStatementReply extends N
         return pkgsnlst;
     }
 
-    protected NetSqlca parseSQLDARD(ColumnMetaData columnMetaData,
+    NetSqlca parseSQLDARD(ColumnMetaData columnMetaData,
                                     boolean skipBytes) throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SQLDARD);
         return parseSQLDARDarray(columnMetaData, skipBytes);
@@ -1750,7 +1757,7 @@ public class NetStatementReply extends N
         return parseSQLRSLRDarray(sections);
     }
 
-    protected ColumnMetaData parseSQLCINRD() throws DisconnectException {
+    ColumnMetaData parseSQLCINRD() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SQLCINRD);
         int ddmLength = getDdmLength();
         ensureBLayerDataInBuffer(ddmLength);

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementRequest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementRequest.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementRequest.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetStatementRequest.java Fri May  3 03:42:14 2013
@@ -52,7 +52,9 @@ import org.apache.derby.shared.common.re
 
 // For performance, should we worry about the ordering of our DDM command parameters
 
-public class NetStatementRequest extends NetPackageRequest implements StatementRequestInterface {
+class NetStatementRequest extends NetPackageRequest
+    implements StatementRequestInterface {
+
     // Integers: build EXTDTA for column i
     private ArrayList<Integer> extdtaPositions_ = null;
 
@@ -350,7 +352,7 @@ public class NetStatementRequest extends
     //   the sqlam and/or prdid must support command and parameters passed to this method,
     //   method will not validate against the connection's level of support
     //
-    void buildOPNQRY(Section section,
+    private void buildOPNQRY(Section section,
                      boolean sendQueryRowSet,
                      int fetchSize) throws SqlException {
         createCommand();
@@ -378,7 +380,7 @@ public class NetStatementRequest extends
     // execute a non-cursor SQL statement sent as command data.
     //
     // precondtions:
-    void buildEXCSQLIMM(Section section,
+    private void buildEXCSQLIMM(Section section,
                         boolean sendQryinsid,
                         long qryinsid) throws SqlException {
         createCommand();
@@ -399,7 +401,7 @@ public class NetStatementRequest extends
     // preconditions:
     //   the sqlam and/or prdid must support command and parameters passed to this method,
     //   method will not validate against the connection's level of support
-    void buildPRPSQLSTT(Section section,
+    private void buildPRPSQLSTT(Section section,
                         String sql,
                         boolean sendRtnsqlda,
                         boolean sendTypsqlda,
@@ -424,7 +426,7 @@ public class NetStatementRequest extends
     // preconditions:
     //   the sqlam and/or prdid must support command and parameters passed to this method,
     //   method will not validate against the connection's level of support
-    void buildEXCSQLSET(Section section)
+    private void buildEXCSQLSET(Section section)
             throws SqlException {
         createCommand();
         markLengthBytes(CodePoint.EXCSQLSET);
@@ -459,7 +461,7 @@ public class NetStatementRequest extends
     // PRCNAM
     // OUTOVROPT
     // RDBNAM
-    void buildEXCSQLSTT(Section section,
+    private void buildEXCSQLSTT(Section section,
                         boolean sendOutexp,
                         boolean outexp,
                         boolean sendPrcnam,
@@ -508,7 +510,7 @@ public class NetStatementRequest extends
     // preconditions:
     //   the sqlam and/or prdid must support command and parameters passed to this method,
     //   method will not validate against the connection's level of support
-    void buildDSCSQLSTT(Section section,
+    private void buildDSCSQLSTT(Section section,
                         boolean sendTypsqlda,
                         int typsqlda) throws SqlException {
         createCommand();
@@ -527,7 +529,7 @@ public class NetStatementRequest extends
     // that an RDB is executing.
     //
     // preconditions:
-    boolean buildSQLDTAcommandData(int numInputColumns,
+    private boolean buildSQLDTAcommandData(int numInputColumns,
                                    ColumnMetaData parameterMetaData,
                                    Object[] inputRow) throws SqlException {
         createEncryptedCommandData();
@@ -584,7 +586,7 @@ public class NetStatementRequest extends
     // Build the FDOCA SQLDTA Late Row Descriptor.
     //
     // preconditions:
-    protected void buildSQLDTA(int numColumns,
+    private void buildSQLDTA(int numColumns,
                                int[][] lidAndLengthOverrides,
                                boolean overrideExists,
                                Hashtable overrideMap,
@@ -605,7 +607,7 @@ public class NetStatementRequest extends
 
     // Build the FDOCA SQLDTAGRP Late Group Descriptor.
     // preconditions:
-    protected void buildSQLDTAGRP(int numVars,
+    private void buildSQLDTAGRP(int numVars,
                                   int[][] lidAndLengthOverrides,
                                   boolean mddRequired,
                                   Hashtable overrideMap) throws SqlException {
@@ -673,12 +675,14 @@ public class NetStatementRequest extends
         return lidAndLengths;
     }
 
-    protected void buildSQLDTARD(int numColumns, int[][] lidAndLengthOverrides) throws SqlException {
+    private void buildSQLDTARD(int numColumns, int[][] lidAndLengthOverrides)
+            throws SqlException {
         buildSQLCADTA(numColumns, lidAndLengthOverrides);
         writeBytes(FdocaConstants.SQLDTARD_RLO_TOSEND);
     }
 
-    protected void buildSQLCADTA(int numColumns, int[][] lidAndLengthOverrides) throws SqlException {
+    private void buildSQLCADTA(int numColumns, int[][] lidAndLengthOverrides)
+            throws SqlException {
         buildSQLDTAGRP(numColumns, lidAndLengthOverrides, false, null);  // false means no mdd override
         writeBytes(FdocaConstants.SQLCADTA_RLO_TOSEND);
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXACallInfo.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXACallInfo.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXACallInfo.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXACallInfo.java Fri May  3 03:42:14 2013
@@ -42,9 +42,8 @@ import java.io.OutputStream;
 import javax.transaction.xa.XAResource;
 import javax.transaction.xa.Xid;
 
-import org.apache.derby.client.am.ClientConnection;
 
-public class NetXACallInfo {
+class NetXACallInfo {
     Xid xid_;                         // current xid
     int xaFlags_;                     // current xaFlags
     /** XA transaction timeout in milliseconds. The value less than 0 means
@@ -53,14 +52,9 @@ public class NetXACallInfo {
     // may not be needed!!!~~~
     int xaFunction_;                  // queued XA function being performed
     int xaRetVal_;                    // xaretval from server
-    boolean xaInProgress_;            // set at start(), reset at commit(),
     //  rollback(), or prepare() on RDONLY
-    boolean xaWasSuspended;           // used to indicate an XA tyrans was suspended
     //  one or more times, overrides empty transaction
-    boolean currConnection_;          // set when actualConn_ is the current connection
-    boolean freeEntry_;               // set when no actualConn_, entry is free / available
-    boolean convReleased_;            // release coversation, reuse successfull = true
-    NetXAResource xaResource_;         // NetXAResource containing this NetXACallInfo
+
     NetXAConnection actualConn_; // the actual connection object, not necessarily
     // the user's connection object
     /* only the first connection object is actually used. The other connection
@@ -72,40 +66,23 @@ public class NetXACallInfo {
     private InputStream in_;
     private OutputStream out_;
 
-    private byte[] uowid_;  // Unit of Work ID
-
-    private boolean readOnlyTransaction_;  // readOnlyTransaction Flag
-
     public NetXACallInfo() {
         xid_ = null;
         xaFlags_ = XAResource.TMNOFLAGS;
         xaTimeoutMillis_ = -1;
-        xaInProgress_ = false;
-        currConnection_ = false;
-        freeEntry_ = true;
-        convReleased_ = false;
         actualConn_ = null;
-        readOnlyTransaction_ = true;
-        xaResource_ = null;
         xaRetVal_ = 0;
-        xaWasSuspended = false;
     }
 
-    public NetXACallInfo(Xid xid, int flags, NetXAResource xares, NetXAConnection actualConn) {
+    NetXACallInfo(Xid xid, int flags, NetXAConnection actualConn) {
         xid_ = xid;
         xaFlags_ = flags;
         xaTimeoutMillis_ = -1;
-        xaInProgress_ = false;
-        currConnection_ = false;
-        freeEntry_ = true;
         actualConn_ = actualConn;
-        readOnlyTransaction_ = true;
-        xaResource_ = xares;
         xaRetVal_ = 0;
-        xaWasSuspended = false;
     }
 
-    public void saveConnectionVariables() {
+    void saveConnectionVariables() {
         in_ = actualConn_.getNetConnection().getInputStream();
         out_ = actualConn_.getNetConnection().getOutputStream();
         crrtkn_ = actualConn_.getCorrelatorToken();
@@ -118,24 +95,6 @@ public class NetXACallInfo {
     public OutputStream getOutputStream() {
         return out_;
     }
-
-    protected void setUOWID(byte[] uowid) {
-        uowid_ = uowid;
-    }
-
-    protected byte[] getUOWID() {
-        return uowid_;
-    }
-
-    protected void setReadOnlyTransactionFlag(boolean flag) {
-        readOnlyTransaction_ = flag;
-    }
-
-    protected boolean getReadOnlyTransactionFlag() {
-        return readOnlyTransaction_;
-    }
-
-
 }
 
 

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnection.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnection.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnection.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnection.java Fri May  3 03:42:14 2013
@@ -90,31 +90,23 @@ public class NetXAConnection {    
         netCon.xares_ = xares;
     }
 
-    public void writeLocalXAStart_() throws SqlException {
-        netCon.netAgent_.netConnectionRequest_.writeLocalXAStart(netCon);
-    }
-
-    public void readLocalXAStart_() throws SqlException {
-        netCon.netAgent_.netConnectionReply_.readLocalXAStart(netCon);
-    }
-
-    public void writeLocalXACommit_() throws SqlException {
+    private void writeLocalXACommit_() throws SqlException {
         netCon.netAgent_.netConnectionRequest_.writeLocalXACommit(netCon);
     }
 
-    public void readLocalXACommit_() throws SqlException {
+    private void readLocalXACommit_() throws SqlException {
         netCon.netAgent_.netConnectionReply_.readLocalXACommit(netCon);
     }
 
-    public void writeLocalXARollback_() throws SqlException {
+    private void writeLocalXARollback_() throws SqlException {
         netCon.netAgent_.netConnectionRequest_.writeLocalXARollback(netCon);
     }
 
-    public void readLocalXARollback_() throws SqlException {
+    private void readLocalXARollback_() throws SqlException {
         netCon.netAgent_.netConnectionReply_.readLocalXARollback(netCon);
     }
 
-    public void writeTransactionStart(ClientStatement statement)
+    void writeTransactionStart(ClientStatement statement)
             throws SqlException {
         //KATHEY  remove below after checking that we don't need it.
         if (!netCon.isXAConnection()) {
@@ -140,24 +132,7 @@ public class NetXAConnection {    
         return;
     }
 
-    public byte[] getUOWID(Xid xid) {
-        NetIndoubtTransaction indoubtTxn = netCon.getIndoubtTransaction(xid);
-        if (indoubtTxn == null) {
-            return null;
-        }
-        byte[] uowid = indoubtTxn.getUOWID();
-        return uowid;
-    }
-
-    public int getPort(Xid xid) {
-        NetIndoubtTransaction indoubtTxn = netCon.getIndoubtTransaction(xid);
-        if (indoubtTxn == null) {
-            return -1;
-        }
-        return indoubtTxn.getPort();
-    }
-
-    public void writeCommit() throws SqlException {
+    void writeCommit() throws SqlException {
         // this logic must be in sync with willAutoCommitGenerateFlow() logic
         int xaState = netCon.getXAState();
         if (xaState == netCon.XA_T0_NOT_ASSOCIATED){
@@ -168,7 +143,7 @@ public class NetXAConnection {    
         }
     }
 
-    public void readCommit() throws SqlException {
+    void readCommit() throws SqlException {
         int xaState = netCon.getXAState();
         NetXACallInfo callInfo = netCon.xares_.callInfoArray_
                 [netCon.currXACallInfoOffset_];
@@ -186,14 +161,14 @@ public class NetXAConnection {    
         }        
     }
 
-    public void writeRollback() throws SqlException {
+    void writeRollback() throws SqlException {
       netCon.xares_.callInfoArray_[
                 netCon.xares_.conn_.currXACallInfoOffset_
                 ].xid_ = netCon.xares_.nullXid;
        writeLocalXARollback_(); 
     }
 
-    public void readRollback() throws SqlException {
+    void readRollback() throws SqlException {
         NetXACallInfo callInfo = netCon.xares_.callInfoArray_
                 [netCon.currXACallInfoOffset_];
         callInfo.xaRetVal_ = XAResource.XA_OK; // initialize XARETVAL
@@ -257,7 +232,7 @@ public class NetXAConnection {    
      * @return NetConnection
      *
      */
-    protected NetConnection createNetConnection (
+    private NetConnection createNetConnection (
             NetLogWriter netLogWriter,
             String user,
             String password,

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionReply.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionReply.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionReply.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionReply.java Fri May  3 03:42:14 2013
@@ -21,7 +21,9 @@
 
 package org.apache.derby.client.net;
 
+import java.util.ArrayList;
 import java.util.HashMap;
+import java.util.List;
 import javax.transaction.xa.XAException;
 import javax.transaction.xa.XAResource;
 import javax.transaction.xa.Xid;
@@ -30,7 +32,7 @@ import org.apache.derby.client.ClientXid
 import org.apache.derby.client.am.ConnectionCallbackInterface;
 import org.apache.derby.client.am.DisconnectException;
 
-public class NetXAConnectionReply extends NetResultSetReply {
+class NetXAConnectionReply extends NetResultSetReply {
     NetXAConnectionReply(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }
@@ -48,8 +50,6 @@ public class NetXAConnectionReply extend
 
         NetXACallInfo callInfo =
                 netAgent_.netConnection_.xares_.callInfoArray_[netAgent_.netConnection_.currXACallInfoOffset_];
-        callInfo.xaInProgress_ = false;
-        callInfo.xaWasSuspended = false;
         connection.completeLocalCommit();
     }
 
@@ -60,7 +60,7 @@ public class NetXAConnectionReply extend
         connection.completeLocalRollback();
     }
 
-    protected void readXaStartUnitOfWork(NetConnection conn) throws DisconnectException {
+    void readXaStartUnitOfWork(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         parseSYNCCTLreply(conn);
         // If we are joining or resuming a global transaction, we let the
@@ -74,7 +74,7 @@ public class NetXAConnectionReply extend
         endOfSameIdChainData();
     }
 
-    protected int readXaEndUnitOfWork(NetConnection conn) throws DisconnectException {
+    int readXaEndUnitOfWork(NetConnection conn) throws DisconnectException {
         // We have ended the XA unit of work, the next logical connection
         // should be reset using the normal procedure.
         conn.xares_.setKeepCurrentIsolationLevel(false);
@@ -90,50 +90,41 @@ public class NetXAConnectionReply extend
         return XAResource.XA_OK;
     }
 
-    protected int readXaPrepare(NetConnection conn) throws DisconnectException {
+    int readXaPrepare(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         int synctype = parseSYNCCTLreply(conn);
         endOfSameIdChainData();
 
-        NetXACallInfo callInfo = conn.xares_.callInfoArray_[conn.currXACallInfoOffset_];
-        if (synctype == XAResource.XA_RDONLY) { // xaretval of read-only, make sure flag agrees
-            callInfo.setReadOnlyTransactionFlag(true);
-        } else { // xaretval NOT read-only, make sure flag agrees
-            callInfo.setReadOnlyTransactionFlag(false);
-        }
         return synctype;
     }
 
-    protected void readXaCommit(NetConnection conn) throws DisconnectException {
+    void readXaCommit(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         parseSYNCCTLreply(conn);
         endOfSameIdChainData();
 
         NetXACallInfo callInfo = conn.xares_.callInfoArray_[conn.currXACallInfoOffset_];
-        callInfo.xaInProgress_ = false;
         conn.completeLocalCommit();
     }
 
-    protected int readXaRollback(NetConnection conn) throws DisconnectException {
+    int readXaRollback(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         parseSYNCCTLreply(conn);
         endOfSameIdChainData();
 
         NetXACallInfo callInfo = conn.xares_.callInfoArray_[conn.currXACallInfoOffset_];
-        callInfo.xaInProgress_ = false;
-        callInfo.xaWasSuspended = false;
         conn.completeLocalRollback();
 
         return XAResource.XA_OK;
     }
 
-    protected void readXaRecover(NetConnection conn) throws DisconnectException {
+    void readXaRecover(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         parseSYNCCTLreply(conn);
         endOfSameIdChainData();
     }
 
-    protected void readXaForget(NetConnection conn) throws DisconnectException {
+    void readXaForget(NetConnection conn) throws DisconnectException {
         startSameIdChainParse();
         parseSYNCCTLreply(conn);
         endOfSameIdChainData();
@@ -201,34 +192,33 @@ public class NetXAConnectionReply extend
     }
 
     // Process XA return value
-    protected int parseXARETVAL() throws DisconnectException {
+    int parseXARETVAL() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.XARETVAL);
         return readInt();
     }
 
     // Process XA return value
-    protected byte parseSYNCTYPE() throws DisconnectException {
+    byte parseSYNCTYPE() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.SYNCTYPE);
         return readByte();
     }
 
     // This method handles the parsing of all command replies and reply data
     // for the SYNNCTL command.
-    protected int parseSYNCCTLreply(ConnectionCallbackInterface connection) throws DisconnectException {
-        int retval = 0;
+    int parseSYNCCTLreply(ConnectionCallbackInterface connection)
+            throws DisconnectException {
         int peekCP = peekCodePoint();
 
         if (peekCP != CodePoint.SYNCCRD) {
             parseSYNCCTLError(peekCP);
             return -1;
         }
-        retval = parseSYNCCRD(connection);
+        int retval = parseSYNCCRD(connection);
 
         peekCP = peekCodePoint();
         while (peekCP == CodePoint.SQLSTT) {
             String s = parseSQLSTT();
             //JCFTMP, need to null out the client list?
-            netAgent_.netConnection_.xares_.addSpecialRegisters(s);
             peekCP = peekCodePoint();
         }
         if (peekCP == CodePoint.PBSD) {
@@ -277,12 +267,12 @@ public class NetXAConnectionReply extend
     }
 
 
-    protected int parseXIDCNT() throws DisconnectException {
+    int parseXIDCNT() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.XIDCNT);
         return readUnsignedShort();
     }
 
-    protected Xid parseXID() throws DisconnectException {
+    Xid parseXID() throws DisconnectException {
         parseLengthAndMatchCodePoint(CodePoint.XID);
         int formatId = readInt();
         int gtridLen = readInt();
@@ -293,23 +283,21 @@ public class NetXAConnectionReply extend
         return new ClientXid(formatId, gtrid, bqual);
     }
 
-    protected HashMap<Xid, NetIndoubtTransaction> parseIndoubtList()
+    List<Xid> parseIndoubtList()
             throws DisconnectException {
-        int port = 0;
-        String sIpAddr = null;
         peekCodePoint();
         parseLengthAndMatchCodePoint(CodePoint.PRPHRCLST);
         int peekCP = peekCodePoint();
         if (peekCP == CodePoint.XIDCNT) {
-            int numXid = parseXIDCNT();
+            parseXIDCNT(); // unused
             peekCP = peekCodePoint();
         }
 
-        HashMap<Xid, NetIndoubtTransaction> indoubtTransactions =
-                new HashMap<Xid, NetIndoubtTransaction>();
+        List<Xid> indoubtTransactions =
+                new ArrayList<Xid>();
         while (peekCP == CodePoint.XID) {
             Xid xid = parseXID();
-            indoubtTransactions.put(xid, new NetIndoubtTransaction(xid, null, null, null, sIpAddr, port));
+            indoubtTransactions.add(xid);
             peekCP = peekCodePoint();
         }
 

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionRequest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionRequest.java?rev=1478635&r1=1478634&r2=1478635&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionRequest.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetXAConnectionRequest.java Fri May  3 03:42:14 2013
@@ -26,7 +26,7 @@ import javax.transaction.xa.Xid;
 
 import org.apache.derby.client.am.SqlException;
 
-public class NetXAConnectionRequest extends NetResultSetRequest {
+class NetXAConnectionRequest extends NetResultSetRequest {
     NetXAConnectionRequest(NetAgent netAgent, int bufferSize) {
         super(netAgent, bufferSize);
     }



Mime
View raw message