Package com.jengine.orm.db

Examples of com.jengine.orm.db.DBException


    public DBSavePoint savePoint() throws DBException {
        try {
            logger.info("Save Point start");
            return new DBSavePoint(getNativeConnection().setSavepoint());
        } catch (SQLException e) {
            throw new DBException(e);
        }
    }
View Full Code Here


    public void releasePoint(DBSavePoint point) throws DBException {
        try {
            getNativeConnection().releaseSavepoint((Savepoint) point.getNativeObject());
            logger.info("Save Point released");
        } catch (SQLException e) {
            throw new DBException(e);
        }
    }
View Full Code Here

    public void rollback(DBSavePoint point) throws DBException {
        try {
            getNativeConnection().rollback((Savepoint) point.getNativeObject());
            logger.info("Save Point rollback");
        } catch (SQLException e) {
            throw new DBException(e);
        }
    }
View Full Code Here

    public boolean isTransactionActive() throws DBException {
        try {
            return getNativeConnection().getAutoCommit() == false;
        } catch (SQLException e) {
            throw new DBException(e);
        }
    }
View Full Code Here

        try {
            StringFilter stringFilter = new StringFilter(query, params);
            stringFilter.config(this);
            this.stringFilters.add(stringFilter);
        } catch (Exception e) {
            throw new DBException(e);
        }

        return this;
    }
View Full Code Here

        for (StringFilter filter : filters) {
            try {
                filter.config(this);
                this.stringFilters.add(filter);
            } catch (Exception e) {
                throw new DBException(e);
            }
        }
        this.stringFilters.addAll(filters);
        return this;
    }
View Full Code Here

    public DBConnection getConnection() throws DBException {
        try {
            return new JDBCConnection(this.dataSource.getConnection());
        } catch (Exception e) {
            throw new DBException(e);
        }
    }
View Full Code Here

        this.user = user;
        this.password = password;
        try {
            Class.forName(driver);
        } catch (ClassNotFoundException e) {
            throw new DBException(e);
        }
    }
View Full Code Here

    public DBConnection getConnection() throws DBException {
        try {
            return new JDBCConnection(DriverManager.getConnection(this.connection, this.user, this.password));
        } catch (Exception e) {
            e.printStackTrace();
            throw new DBException(e);
        }
    }
View Full Code Here

    public Cluster filterCluster(String query, Object ... params) throws DBException {
        try {
            stringFilters.add(new StringFilter(query, toList(params)));
        } catch (Exception e) {
            throw new DBException(e);
        }
        return this;
    }
View Full Code Here

TOP

Related Classes of com.jengine.orm.db.DBException

Copyright © 2018 www.massapicom. 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.