/** * <p>Create entity.</p> * @param pAddParam additional param * @return entity instance * @throws Exception - an exception **/ @Override public final Account createEntity( final Map<String, Object> pAddParam) throws Exception { Account entity = new Account(); addTypeCodeIntoAttrs(pAddParam); entity.setIsNew(true); return entity; }
/** * <p>Retrieve copy of entity from DB by given ID.</p> * @param pAddParam additional param * @param pId ID * @return entity or null * @throws Exception - an exception **/ @Override public final Account retrieveCopyEntity( final Map<String, Object> pAddParam, final Object pId) throws Exception { Account entity = getSrvOrm() .retrieveCopyEntity(Account.class, pId); entity.setIsNew(true); addTypeCodeIntoAttrs(pAddParam); addAccSettingsIntoAttrs(pAddParam); return entity; }