Package com.dbxml.db.core.transaction

Examples of com.dbxml.db.core.transaction.Transaction.commit()


         }
      }
    finally {
      if ( tx.getStatus() == Transaction.ACTIVE ) {
        try {
           tx.commit();
        }
        catch ( DBException e ) {
          e.printStackTrace(System.err);
        }
      }
View Full Code Here


         }
      }
    finally {
      if ( tx.getStatus() == Transaction.ACTIVE ) {
        try {
           tx.commit();
        }
        catch ( DBException e ) {
          e.printStackTrace(System.err);
        }
      }
View Full Code Here

         tx.cancel();
         throw e;
      }
    finally {
      if ( tx.getStatus() == Transaction.ACTIVE )
        tx.commit();
    }
   }

   private Collection getAbsoluteCollection(String path) throws dbXMLException {
      if ( path.startsWith("/") ) {
View Full Code Here

         catch ( DBException ex ) {
         }
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }

      return doc;
   }
View Full Code Here

         tx.cancel();
         throw new DBException(FaultCodes.COL_CANNOT_RETRIEVE, "Can't convert Document '" + docKey + "' to text", e);
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }
   }

   public static final String[] PARAMS_insertDocument = {"document"};
View Full Code Here

         tx.cancel();
         throw new DBException(FaultCodes.COL_CANNOT_STORE, "Can't parse Document", e);
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }
   }

   public static final String[] PARAMS_setDocument = {"docKey", "document"};
View Full Code Here

   public void setDocument(String docKey, String document) throws DBException {
      Transaction tx = new Transaction();
      try {
         DocumentTable dt = DTSMHelper.textToTable(document, col.getSymbols());
         col.setDocument(tx, docKey, dt);
         tx.commit();
      }
      catch ( DBException e ) {
         tx.cancel();
         throw e;
      }
View Full Code Here

         tx.cancel();
         throw new DBException(FaultCodes.COL_CANNOT_STORE, "Can't parse Document '" + docKey + "'", e);
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }
   }

   public static final String[] PARAMS_remove = {"docKey"};
View Full Code Here

         tx.cancel();
         throw e;
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }
   }

   public String[] listKeys() throws DBException {
      Transaction tx = new Transaction();
View Full Code Here

         tx.cancel();
         throw e;
      }
      finally {
         if ( tx.getStatus() == Transaction.ACTIVE )
            tx.commit();
      }
   }

   public long getKeyCount() throws DBException {
      Transaction tx = new Transaction();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.