import javax.ejb.Stateless;
import javax.persistence.NoResultException;
import javax.persistence.Query;
-import org.mxchange.jcontacts.contact.utils.ContactUtils;
import org.mxchange.jcontacts.exceptions.ContactNotFoundException;
import org.mxchange.jfinancials.database.BaseFinancialsDatabaseBean;
import javax.persistence.PersistenceException;
import javax.persistence.Query;
import org.mxchange.jcontacts.contact.Contact;
+import org.mxchange.jcontacts.contact.ContactUtils;
import org.mxchange.jfinancials.database.BaseFinancialsDatabaseBean;
import org.mxchange.jphone.phonenumbers.fax.DialableFaxNumber;
import org.mxchange.jphone.phonenumbers.landline.DialableLandLineNumber;
assert (detachedUser instanceof User) : MessageFormat.format("User with id {0} not merged, but should be.", user.getUserId()); //NOI18N
// Copy all data
- detachedUser.copyAll(user);
+ UserUtils.copyAll(user, detachedUser);
// Set as updated
detachedUser.setUserUpdated(new GregorianCalendar());
assert (detachedUser instanceof User) : MessageFormat.format("User with id {0} not merged, but should be.", user.getUserId()); //NOI18N
// Copy all data
- detachedUser.copyAll(user);
+ UserUtils.copyAll(user, detachedUser);
// Set as updated
detachedUser.setUserUpdated(new GregorianCalendar());
Contact detachedContact = this.getEntityManager().merge(foundContact);
// Copy all
- detachedContact.copyAll(user.getUserContact());
+ ContactUtils.copyAll(user.getUserContact(), detachedContact);
// Set it back in user
user.setUserContact(detachedContact);