Package com.jengine.orm.db

Examples of com.jengine.orm.db.DBException


    public void close() throws DBException {
        try {
            getNativeConnection().close();
        } catch (ORMException e) {
            throw new DBException(e);
        }
    }
View Full Code Here


            getPersistence().update(entity, false);
            obj.setNew(false);
            updateManyReference(obj);
            calcFunctionField(obj);
        } catch (SystemException e) {
            throw new DBException(e);
        }
        return obj;
    }
View Full Code Here

            setEntityAttributes(entity, obj);
            getPersistence().update(entity, true);
            updateManyReference(obj);
            calcFunctionField(obj);
        } catch (SystemException e) {
            throw new DBException(e);
        }
        return obj;
    }
View Full Code Here

    public void remove(Model obj) throws DBException {
        try {
            getPersistence().remove(obj.getPrimaryKey());
        } catch (Exception e) {
            throw new DBException(e);
        }
    }
View Full Code Here

    public DBConnection getConnection() throws DBException {
        try {
            return new LiferayConnection(getSessionFactory().openSession());
        } catch (Exception e) {
            throw new DBException(e);
        }
    }
View Full Code Here

                qpos.add(item);
            }
            log.debug(sql + "\n" + params);
            query.executeUpdate();
        } catch (Exception e) {
            throw new DBException(e);
        } finally {
            closeConnection(dbConnection);
        }
    }
View Full Code Here

//                    }
//                }
//            }
//            System.out.println();
        } catch (Exception e) {
            throw new DBException(e);
        } finally {
            closeConnection(dbConnection);
        }

        return items;
View Full Code Here

        try {
            obj = cls.newInstance();
            obj.setModelClass(this);
        } catch (InstantiationException e) {
            e.printStackTrace();
            throw new DBException(e.getMessage());
        } catch (IllegalAccessException e) {
            e.printStackTrace();
            throw new DBException(e.getMessage());
        }
        return (T) obj;
    }
View Full Code Here

    public Object getValue(Model obj) throws DBException {
        try {
            Method method = obj.getClass().getMethod(methodName);
            return method.invoke(obj);
        } catch (Exception e) {
            throw new DBException(e);
        }
    }
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.