Class MultiArgInstantiationPolicy
- java.lang.Object
-
- org.eclipse.persistence.internal.core.descriptors.CoreInstantiationPolicy
-
- org.eclipse.persistence.internal.descriptors.InstantiationPolicy
-
- org.eclipse.persistence.internal.jaxb.MultiArgInstantiationPolicy
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable
public class MultiArgInstantiationPolicy extends org.eclipse.persistence.internal.descriptors.InstantiationPolicyPurpose: Provide a version of Instantiation Policy that can make use of a multiple argument factory method. The defaultValues specified on this policy will be passed in to the factory method for the parameter values. This is required for certain JAXB generated classes that have no 0 arg constructor and a factory method with multiple arguments.- Author:
- mmacivor
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MultiArgInstantiationPolicy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.ObjectbuildNewInstanceUsingFactory()Build and return a new instance, using the factory.voidconvertClassNamesToClasses(java.lang.ClassLoader loader)protected voidinitializeMethod()voidsetDefaultValues(java.lang.Object[] values)voidsetParameterTypeNames(java.lang.String[] parameterTypeNames)voidsetParameterTypes(java.lang.Class[] parameterTypes)-
Methods inherited from class org.eclipse.persistence.internal.descriptors.InstantiationPolicy
buildDefaultConstructor, buildDefaultConstructorFor, buildFactory, buildFactoryDefaultConstructor, buildFactoryUsingDefaultConstructor, buildFactoryUsingStaticMethod, buildMethod, buildNewInstance, buildNewInstanceUsingDefaultConstructor, clone, getDefaultConstructor, getDescriptor, getFactory, getFactoryClass, getFactoryClassName, getFactoryMethodName, getMethod, getMethodName, initialize, isUsingDefaultConstructor, setDefaultConstructor, setDescriptor, setFactory, setFactoryClass, setFactoryClassName, setFactoryMethodName, setMethod, setMethodName, toString, useDefaultConstructorInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useMethodInstantiationPolicy
-
-
-
-
Method Detail
-
setParameterTypeNames
public void setParameterTypeNames(java.lang.String[] parameterTypeNames)
-
setParameterTypes
public void setParameterTypes(java.lang.Class[] parameterTypes)
-
setDefaultValues
public void setDefaultValues(java.lang.Object[] values)
-
convertClassNamesToClasses
public void convertClassNamesToClasses(java.lang.ClassLoader loader)
- Overrides:
convertClassNamesToClassesin classorg.eclipse.persistence.internal.descriptors.InstantiationPolicy
-
initializeMethod
protected void initializeMethod() throws org.eclipse.persistence.exceptions.DescriptorException- Overrides:
initializeMethodin classorg.eclipse.persistence.internal.descriptors.InstantiationPolicy- Throws:
org.eclipse.persistence.exceptions.DescriptorException
-
buildNewInstanceUsingFactory
protected java.lang.Object buildNewInstanceUsingFactory() throws org.eclipse.persistence.exceptions.DescriptorExceptionBuild and return a new instance, using the factory. The factory can be null, in which case the method is a static method defined by the descriptor class.- Overrides:
buildNewInstanceUsingFactoryin classorg.eclipse.persistence.internal.descriptors.InstantiationPolicy- Throws:
org.eclipse.persistence.exceptions.DescriptorException
-
-