static PropertySet createDatabaseBackedPropertySet() { return new CachingOfBizPropertySet(SEQUENCE, ID); } }
/** * Gets a caching property set that is associated with the specified entity. * This method should <em>almost always</em> be preferred over {@link #getPropertySet(String,Long)}, * because this implementation will be more efficient for most cases. It is also <em>safer</em> * to use the caching property set, because it will notify any other caching property sets if their information * has become stale. The non-caching property set returned by the other method does not do this, so any caching * property sets created by other code will not be notified of changes. * * @param entityName the entity model name of the property set's owning entity * @param entityId the entity ID of the property set's owning entity * @return the caching property set * @since 6.2 */ public static PropertySet getCachingPropertySet(String entityName, Long entityId) { return new CachingOfBizPropertySet(entityName, entityId); }
@Nonnull public PropertySet buildCachingPropertySet(final String entityName, final Long entityId) { return new CachingOfBizPropertySet(ofBizPropertyEntryStore, entityName, entityId); }
/** * Gets a caching property set that is associated with the specified generic value. * This method should <em>almost always</em> be preferred over {@link #getPropertySet(GenericValue)}, * because this implementation will be more efficient for most cases. It is also <em>safer</em> * to use the caching property set, because it will notify any other caching property sets if their information * has become stale. The non-caching property set returned by the other method does not do this, so any caching * property sets created by other code will not be notified of changes. * * @param gv the generic value which owns the property set * @return the caching property set */ public static PropertySet getCachingPropertySet(GenericValue gv) { return new CachingOfBizPropertySet(gv.getEntityName(), gv.getLong("id")); }