/** * @see DomainObjectContainer#newPersistentInstance(Class) * @deprecated - see {@link DomainObjectContainer#newPersistentInstance(Class)} for rationale. */ @Deprecated protected <T> T newPersistentInstance(final Class<T> ofClass) { return getContainer().newPersistentInstance(ofClass); }
/** * Returns a new instance of the specified class that will have been * persisted. * * <p> * This method isn't quite deprecated, but generally consider using * {@link #newTransientInstance(Class)} instead. */ protected <T> T newPersistentInstance(final Class<T> ofClass) { return getContainer().newPersistentInstance(ofClass); }