Package gwlpr.database.jpa.exceptions

Examples of gwlpr.database.jpa.exceptions.NonexistentEntityException


        } catch (Exception ex) {
            String msg = ex.getLocalizedMessage();
            if (msg == null || msg.length() == 0) {
                String id = account.getEMail();
                if (findAccount(id) == null) {
                    throw new NonexistentEntityException("The account with id " + id + " no longer exists.");
                }
            }
            throw ex;
        } finally {
            if (em != null) {
View Full Code Here


            Account account;
            try {
                account = em.getReference(Account.class, id);
                account.getEMail();
            } catch (EntityNotFoundException enfe) {
                throw new NonexistentEntityException("The account with id " + id + " no longer exists.", enfe);
            }
            List<String> illegalOrphanMessages = null;
            Collection<Storagetab> storagetabCollectionOrphanCheck = account.getStoragetabCollection();
            for (Storagetab storagetabCollectionOrphanCheckStoragetab : storagetabCollectionOrphanCheck) {
                if (illegalOrphanMessages == null) {
View Full Code Here

        } catch (Exception ex) {
            String msg = ex.getLocalizedMessage();
            if (msg == null || msg.length() == 0) {
                AttributepointPK id = attributepoint.getAttributepointPK();
                if (findAttributepoint(id) == null) {
                    throw new NonexistentEntityException("The attributepoint with id " + id + " no longer exists.");
                }
            }
            throw ex;
        } finally {
            if (em != null) {
View Full Code Here

            Attributepoint attributepoint;
            try {
                attributepoint = em.getReference(Attributepoint.class, id);
                attributepoint.getAttributepointPK();
            } catch (EntityNotFoundException enfe) {
                throw new NonexistentEntityException("The attributepoint with id " + id + " no longer exists.", enfe);
            }
            Character character = attributepoint.getCharacter();
            if (character != null) {
                character.getAttributepointCollection().remove(attributepoint);
                character = em.merge(character);
View Full Code Here

        } catch (Exception ex) {
            String msg = ex.getLocalizedMessage();
            if (msg == null || msg.length() == 0) {
                Integer id = attribute.getId();
                if (findAttribute(id) == null) {
                    throw new NonexistentEntityException("The attribute with id " + id + " no longer exists.");
                }
            }
            throw ex;
        } finally {
            if (em != null) {
View Full Code Here

            Attribute attribute;
            try {
                attribute = em.getReference(Attribute.class, id);
                attribute.getId();
            } catch (EntityNotFoundException enfe) {
                throw new NonexistentEntityException("The attribute with id " + id + " no longer exists.", enfe);
            }
            List<String> illegalOrphanMessages = null;
            Collection<Skill> skillCollectionOrphanCheck = attribute.getSkillCollection();
            for (Skill skillCollectionOrphanCheckSkill : skillCollectionOrphanCheck) {
                if (illegalOrphanMessages == null) {
View Full Code Here

        } catch (Exception ex) {
            String msg = ex.getLocalizedMessage();
            if (msg == null || msg.length() == 0) {
                HstringPK id = hstring.getHstringPK();
                if (findHstring(id) == null) {
                    throw new NonexistentEntityException("The hstring with id " + id + " no longer exists.");
                }
            }
            throw ex;
        } finally {
            if (em != null) {
View Full Code Here

            Hstring hstring;
            try {
                hstring = em.getReference(Hstring.class, id);
                hstring.getHstringPK();
            } catch (EntityNotFoundException enfe) {
                throw new NonexistentEntityException("The hstring with id " + id + " no longer exists.", enfe);
            }
            em.remove(hstring);
            em.getTransaction().commit();
        } finally {
            if (em != null) {
View Full Code Here

TOP

Related Classes of gwlpr.database.jpa.exceptions.NonexistentEntityException

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.