Package net.stinfoservices.pacifiq.shared.exception

Examples of net.stinfoservices.pacifiq.shared.exception.CustomException


            // in postgres, it seems that default order by is "order by version" (and perhaps then id),
            // so I had "order by id" here, stopping moving lines in alerts CRUD
            return (Collections.unmodifiableList(entityManager.createQuery("SELECT o FROM " + IModel.DATABASE_PRE + "Alert o order by id")
                    .setFirstResult(firstResult).setMaxResults(maxResults).getResultList()));
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here


            LOGGER.info(MessageFormat.format(ResourceBundle.getBundle("system").getString("OBJECT_SAVED"), this.getClass().getSimpleName(),
                    a.getId()));

            return (a);
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

            entityManager.remove(nalert);
            LOGGER.info(MessageFormat.format(ResourceBundle.getBundle("system").getString("OBJECT_DELETED"), this.getClass().getSimpleName(),
                    nalert.getId()));
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

                c = result.get(0);
            }

            return (c);
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

    @Override
    public void updateLicenseNumber(Long id, String licenseNumber) throws Exception {
        try {
            dsp5ServiceCore.updateLicenseNumber(id, licenseNumber);
        } catch (JpaSystemException e) {
            throw new CustomException(MessageFormat.format(dsp5ServiceCore.getMessageResource().getString("EXCEPTION_LICENSE_NUMBER_ALREADY_EXISTS"),
                    licenseNumber));
        }

    }
View Full Code Here

    @Override
    public Long saveDocument(DSP5DTO dsp5) throws Exception {
        try {
            return dsp5ServiceCore.saveDocument(dsp5);
        } catch (JpaSystemException e) {
            throw new CustomException(MessageFormat.format(dsp5ServiceCore.getMessageResource().getString("EXCEPTION_LICENSE_NUMBER_ALREADY_EXISTS"),
                    dsp5.getLicenseNumber()));
        }
    }
View Full Code Here

        }

        try {
            return (entityManager.find(Profile.class, id));
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

    @Override
    public List<Profile> findAll() throws Exception {
        try {
            return (Collections.unmodifiableList(entityManager.createQuery("SELECT o FROM " + IModel.DATABASE_PRE + "Profile o").getResultList()));
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

    public List<Profile> findEntries(int firstResult, int maxResults) throws Exception {
        try {
            return (Collections.unmodifiableList(entityManager.createQuery("SELECT o FROM " + IModel.DATABASE_PRE + "Profile o")
                    .setFirstResult(firstResult).setMaxResults(maxResults).getResultList()));
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

            LOGGER.info(MessageFormat.format(ResourceBundle.getBundle("system").getString("OBJECT_SAVED"), this.getClass().getSimpleName(),
                    p.getId()));

            return (p);
        } catch (Exception ex) {
            throw new CustomException(ex);
        }
    }
View Full Code Here

TOP

Related Classes of net.stinfoservices.pacifiq.shared.exception.CustomException

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.