Examples of EXistException


Examples of org.exist.EXistException

            broker = factory.getBrokerPool().get(user);
            try {
              collection = broker.openCollection(collUri, Lock.READ_LOCK);
              if (collection == null) {
                  transact.abort(transaction);
                  throw new EXistException("collection " + collUri + " not found!");
              }
            } finally {
              if (collection != null)
                {collection.release(Lock.READ_LOCK);}
            }
            final CollectionConfigurationManager mgr = factory.getBrokerPool().getConfigurationManager();
            mgr.addConfiguration(transaction, broker, collection, configuration);
            transact.commit(transaction);
            LOG.info("Configured '" + collection.getURI() + "'")
        } catch (final CollectionConfigurationException e) {
            transact.abort(transaction);
            throw new EXistException(e.getMessage());
        } finally {
            transact.close(transaction);
            factory.getBrokerPool().release(broker);
        }
        return false;
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.