@Override public HRClient updateImpl(com.liferay.hr.model.HRClient hrClient, boolean merge) throws SystemException { hrClient = toUnwrappedModel(hrClient); Session session = null; try { session = openSession(); BatchSessionUtil.update(session, hrClient, merge); hrClient.setNew(false); } catch (Exception e) { throw processException(e); } finally { closeSession(session); } FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST); EntityCacheUtil.putResult( HRClientModelImpl.ENTITY_CACHE_ENABLED, HRClientImpl.class, hrClient.getPrimaryKey(), hrClient); return hrClient; }
/** * Creates a new h r client with the primary key. Does not add the h r client to the database. * * @param hrClientId the primary key for the new h r client * @return the new h r client */ public HRClient create(long hrClientId) { HRClient hrClient = new HRClientImpl(); hrClient.setNew(true); hrClient.setPrimaryKey(hrClientId); return hrClient; }