- java.lang.Object
-
- com.thoughtworks.qdox.model.impl.AbstractJavaModel
-
- com.thoughtworks.qdox.model.impl.AbstractBaseJavaEntity
-
- com.thoughtworks.qdox.model.impl.AbstractJavaEntity
-
- com.thoughtworks.qdox.model.impl.AbstractInheritableJavaEntity
-
- com.thoughtworks.qdox.model.impl.DefaultJavaExecutable
-
- com.thoughtworks.qdox.model.impl.DefaultJavaConstructor
-
- All Implemented Interfaces:
JavaAnnotatedElement
,JavaConstructor
,JavaExecutable
,JavaGenericDeclaration
,JavaMember
,JavaModel
,Serializable
public class DefaultJavaConstructor extends DefaultJavaExecutable implements JavaConstructor
- Since:
- 2.0
- Author:
- Robert
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description DefaultJavaConstructor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
String
getCodeBlock()
List<JavaTypeVariable<JavaConstructor>>
getTypeParameters()
Equivalent ofGenericDeclaration.getTypeParameters()
int
hashCode()
void
setTypeParameters(List<JavaTypeVariable<JavaConstructor>> typeParameters)
boolean
signatureMatches(List<JavaType> parameterTypes)
Returnstrue
if this constructor matches the parameterTypes, assuming it's a non-varArg constructor.boolean
signatureMatches(List<JavaType> parameterTypes, boolean varArgs)
Returnstrue
if this constructor matches the parameterTypes and matches the varArg argument.String
toString()
-
Methods inherited from class com.thoughtworks.qdox.model.impl.DefaultJavaExecutable
getCallSignature, getExceptions, getExceptionTypes, getParameterByName, getParameters, getParameterTypes, getParameterTypes, getReturns, getSignature, getSourceCode, getTagsByName, isPublic, isVarArgs, setExceptions, setParameters, setSourceCode
-
Methods inherited from class com.thoughtworks.qdox.model.impl.AbstractInheritableJavaEntity
getTagByName
-
Methods inherited from class com.thoughtworks.qdox.model.impl.AbstractJavaEntity
getDeclaringClass, getModifiers, getName, isAbstract, isFinal, isNative, isPrivate, isProtected, isStatic, isStrictfp, isSynchronized, isTransient, isVolatile, setDeclaringClass, setModifiers, setName
-
Methods inherited from class com.thoughtworks.qdox.model.impl.AbstractBaseJavaEntity
getAnnotations, getComment, getNamedParameter, getSource, getTagByName, getTags, getTagsByName, setAnnotations, setComment, setSource, setTags
-
Methods inherited from class com.thoughtworks.qdox.model.impl.AbstractJavaModel
getLineNumber, getModelWriter, setLineNumber, setModelWriterFactory
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.thoughtworks.qdox.model.JavaAnnotatedElement
getAnnotations, getComment, getNamedParameter, getTagByName, getTags, getTagsByName
-
Methods inherited from interface com.thoughtworks.qdox.model.JavaExecutable
getCallSignature, getDeclaringClass, getExceptions, getExceptionTypes, getParameterByName, getParameters, getParameterTypes, getParameterTypes, getSourceCode, isVarArgs
-
Methods inherited from interface com.thoughtworks.qdox.model.JavaMember
getModifiers, getName, isAbstract, isFinal, isNative, isPrivate, isProtected, isPublic, isStatic, isStrictfp, isSynchronized, isTransient, isVolatile
-
Methods inherited from interface com.thoughtworks.qdox.model.JavaModel
getLineNumber
-
-
-
-
Method Detail
-
setTypeParameters
public void setTypeParameters(List<JavaTypeVariable<JavaConstructor>> typeParameters)
-
getTypeParameters
public List<JavaTypeVariable<JavaConstructor>> getTypeParameters()
Equivalent ofGenericDeclaration.getTypeParameters()
- Specified by:
getTypeParameters
in interfaceJavaGenericDeclaration
- Returns:
- a list of typeParameters, never
null
-
signatureMatches
public boolean signatureMatches(List<JavaType> parameterTypes)
Returnstrue
if this constructor matches the parameterTypes, assuming it's a non-varArg constructor.- Specified by:
signatureMatches
in interfaceJavaConstructor
- Parameters:
parameterTypes
- the parameter types- Returns:
true
if signature matches, otherwisefalse
-
signatureMatches
public boolean signatureMatches(List<JavaType> parameterTypes, boolean varArgs)
Returnstrue
if this constructor matches the parameterTypes and matches the varArg argument.- Specified by:
signatureMatches
in interfaceJavaConstructor
- Overrides:
signatureMatches
in classDefaultJavaExecutable
- Parameters:
parameterTypes
- the parameter typesvarArgs
-true
if the last argument should be a varArg, otherwisefalse
- Returns:
true
if signature matches, otherwisefalse
-
getCodeBlock
public String getCodeBlock()
- Specified by:
getCodeBlock
in interfaceJavaModel
- Returns:
- the codeblock
-
-