Examples of EquippedSkill


Examples of gwlpr.database.entities.EquippedSkill

        equippedSkill.getEquippedSkillPK().setCharacterID(equippedSkill.getCharacter().getId());
        EntityManager em = null;
        try {
            em = getEntityManager();
            em.getTransaction().begin();
            EquippedSkill persistentEquippedSkill = em.find(EquippedSkill.class, equippedSkill.getEquippedSkillPK());
            Skill skillOld = persistentEquippedSkill.getSkill();
            Skill skillNew = equippedSkill.getSkill();
            Character characterOld = persistentEquippedSkill.getCharacter();
            Character characterNew = equippedSkill.getCharacter();
            if (skillNew != null) {
                skillNew = em.getReference(skillNew.getClass(), skillNew.getId());
                equippedSkill.setSkill(skillNew);
            }
View Full Code Here

Examples of gwlpr.database.entities.EquippedSkill

    public void destroy(EquippedSkillPK id) throws NonexistentEntityException {
        EntityManager em = null;
        try {
            em = getEntityManager();
            em.getTransaction().begin();
            EquippedSkill equippedSkill;
            try {
                equippedSkill = em.getReference(EquippedSkill.class, id);
                equippedSkill.getEquippedSkillPK();
            } catch (EntityNotFoundException enfe) {
                throw new NonexistentEntityException("The equippedSkill with id " + id + " no longer exists.", enfe);
            }
            Skill skill = equippedSkill.getSkill();
            if (skill != null) {
                skill.getEquippedSkillCollection().remove(equippedSkill);
                skill = em.merge(skill);
            }
            Character character = equippedSkill.getCharacter();
            if (character != null) {
                character.getEquippedSkillCollection().remove(equippedSkill);
                character = em.merge(character);
            }
            em.remove(equippedSkill);
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.