/** * INTERNAL: */ public CopyPolicy getCopyPolicy() { return new InstantiationCopyPolicy(); } }
public Object buildClone(Object domainObject, Session session) throws DescriptorException { return getDescriptor().getObjectBuilder().buildNewInstance(); }
public Object buildClone(Object domainObject, Session session) throws DescriptorException { return getDescriptor().getObjectBuilder().buildNewInstance(); }
/** * INTERNAL: * Returns the copy policy. */ public CopyPolicy getCopyPolicy() { // Lazy initialize for XML deployment. if (copyPolicy == null) { setCopyPolicy(new InstantiationCopyPolicy()); } return copyPolicy; }
public Object buildClone(Object domainObject, Session session) throws DescriptorException { return getDescriptor().getObjectBuilder().buildNewInstance(); }
/** * INTERNAL: * Returns the copy policy. */ public CopyPolicy getCopyPolicy() { // Lazy initialize for XML deployment. if (copyPolicy == null) { setCopyPolicy(new InstantiationCopyPolicy()); } return copyPolicy; }
/** * INTERNAL: * Returns the copy policy. */ public CopyPolicy getCopyPolicy() { // Lazy initialize for XML deployment. if (copyPolicy == null) { setCopyPolicy(new InstantiationCopyPolicy()); } return copyPolicy; }
/** * PUBLIC: * Specifies that the creation of clones within a unit of work is done by building * a new instance using the * technique indicated by the descriptor's instantiation policy * (which by default is to use the * the default constructor). This new instance is then populated by using the * descriptor's mappings to copy attributes from the original to the clone. * This is the default. * If another mechanism is desired the copy policy allows for a clone method to be called. * * @see #useCloneCopyPolicy() * @see #useCloneCopyPolicy(String) * @see #useDefaultConstructorInstantiationPolicy() * @see #useMethodInstantiationPolicy(String) * @see #useFactoryInstantiationPolicy(Class, String) * @see #useFactoryInstantiationPolicy(Class, String, String) * @see #useFactoryInstantiationPolicy(Object, String) */ public void useInstantiationCopyPolicy() { setCopyPolicy(new InstantiationCopyPolicy()); }
/** * PUBLIC: * Specifies that the creation of clones within a unit of work is done by building * a new instance using the * technique indicated by the descriptor's instantiation policy * (which by default is to use the * the default constructor). This new instance is then populated by using the * descriptor's mappings to copy attributes from the original to the clone. * This is the default. * If another mechanism is desired the copy policy allows for a clone method to be called. * * @see #useCloneCopyPolicy() * @see #useCloneCopyPolicy(String) * @see #useDefaultConstructorInstantiationPolicy() * @see #useMethodInstantiationPolicy(String) * @see #useFactoryInstantiationPolicy(Class, String) * @see #useFactoryInstantiationPolicy(Class, String, String) * @see #useFactoryInstantiationPolicy(Object, String) */ public void useInstantiationCopyPolicy() { setCopyPolicy(new InstantiationCopyPolicy()); }
/** * PUBLIC: * Specifies that the creation of clones within a unit of work is done by building * a new instance using the * technique indicated by the descriptor's instantiation policy * (which by default is to use the * the default constructor). This new instance is then populated by using the * descriptor's mappings to copy attributes from the original to the clone. * This is the default. * If another mechanism is desired the copy policy allows for a clone method to be called. * * @see #useCloneCopyPolicy() * @see #useCloneCopyPolicy(String) * @see #useDefaultConstructorInstantiationPolicy() * @see #useMethodInstantiationPolicy(String) * @see #useFactoryInstantiationPolicy(Class, String) * @see #useFactoryInstantiationPolicy(Class, String, String) * @see #useFactoryInstantiationPolicy(Object, String) */ public void useInstantiationCopyPolicy() { setCopyPolicy(new InstantiationCopyPolicy()); }