Class InvokableImpl
- java.lang.Object
-
- org.apache.xmlbeans.impl.jam.internal.elements.ElementImpl
-
- org.apache.xmlbeans.impl.jam.internal.elements.AnnotatedElementImpl
-
- org.apache.xmlbeans.impl.jam.internal.elements.MemberImpl
-
- org.apache.xmlbeans.impl.jam.internal.elements.InvokableImpl
-
- All Implemented Interfaces:
java.lang.Comparable
,JAnnotatedElement
,JElement
,JInvokable
,JMember
,MAnnotatedElement
,MElement
,MInvokable
,MMember
- Direct Known Subclasses:
ConstructorImpl
,MethodImpl
public abstract class InvokableImpl extends MemberImpl implements MInvokable
-
-
Field Summary
-
Fields inherited from class org.apache.xmlbeans.impl.jam.internal.elements.ElementImpl
NO_ANNOTATION, NO_CLASS, NO_COMMENT, NO_CONSTRUCTOR, NO_FIELD, NO_METHOD, NO_NODE, NO_PACKAGE, NO_PARAMETER, NO_PROPERTY
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addException(java.lang.String qcname)
Adds a declaration of a checked exception of the given type.void
addException(JClass exceptionClass)
Adds a declaration of a checked exception of the given type.MParameter
addNewParameter()
Creates a new parameter on this method of type java.lang.Object and with a default name.void
addUnqualifiedException(java.lang.String ucname)
JClass[]
getExceptionTypes()
Returns representations of the type of each of the exceptions which can be thrown by this method.MParameter[]
getMutableParameters()
Returns all of the parameters on this method, or an empty array if there are none.JParameter[]
getParameters()
Returns representations of the parameters taken by this method.java.lang.String
getQualifiedName()
Returns a qualified name for this abstraction.void
removeException(java.lang.String exceptionClassName)
Removes a declaration of a checked exception of the named class.void
removeException(JClass exceptionClass)
Removes a declaration of a checked exception of the given class.void
removeParameter(MParameter parameter)
Removes the given parameter.void
setUnqualifiedThrows(java.util.List classnames)
-
Methods inherited from class org.apache.xmlbeans.impl.jam.internal.elements.MemberImpl
getContainingClass, getModifiers, isPackagePrivate, isPrivate, isProtected, isPublic, setModifiers
-
Methods inherited from class org.apache.xmlbeans.impl.jam.internal.elements.AnnotatedElementImpl
addAnnotationForProxy, addLiteralAnnotation, createComment, findOrCreateAnnotation, getAllJavadocTags, getAnnotation, getAnnotation, getAnnotationProxy, getAnnotations, getAnnotationValue, getComment, getEditableProxy, getMutableAnnotation, getMutableAnnotations, getMutableComment, removeAnnotation, removeComment
-
Methods inherited from class org.apache.xmlbeans.impl.jam.internal.elements.ElementImpl
compareTo, createSourcePosition, defaultName, equals, getArtifact, getClassLoader, getContext, getMutableSourcePosition, getParent, getSimpleName, getSourcePosition, hashCode, removeSourcePosition, setArtifact, setSimpleName, toString
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.JAnnotatedElement
getAllJavadocTags, getAnnotation, getAnnotation, getAnnotationProxy, getAnnotations, getAnnotationValue, getComment
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.JElement
accept, getArtifact, getParent, getSimpleName, getSourcePosition, toString
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.JMember
getContainingClass, getModifiers, isPackagePrivate, isPrivate, isProtected, isPublic
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.mutable.MAnnotatedElement
addLiteralAnnotation, createComment, findOrCreateAnnotation, getMutableAnnotation, getMutableAnnotations, getMutableComment, removeComment
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.mutable.MElement
accept, createSourcePosition, getClassLoader, getMutableSourcePosition, removeSourcePosition, setArtifact, setSimpleName
-
Methods inherited from interface org.apache.xmlbeans.impl.jam.mutable.MMember
setModifiers
-
-
-
-
Method Detail
-
addException
public void addException(JClass exceptionClass)
Description copied from interface:MInvokable
Adds a declaration of a checked exception of the given type.
- Specified by:
addException
in interfaceMInvokable
-
addException
public void addException(java.lang.String qcname)
Description copied from interface:MInvokable
Adds a declaration of a checked exception of the given type.
- Specified by:
addException
in interfaceMInvokable
-
addUnqualifiedException
public void addUnqualifiedException(java.lang.String ucname)
-
removeException
public void removeException(java.lang.String exceptionClassName)
Description copied from interface:MInvokable
Removes a declaration of a checked exception of the named class. Does nothing if no such declaration exists.- Specified by:
removeException
in interfaceMInvokable
-
removeException
public void removeException(JClass exceptionClass)
Description copied from interface:MInvokable
Removes a declaration of a checked exception of the given class. Does nothing if no such declaration exists.- Specified by:
removeException
in interfaceMInvokable
-
addNewParameter
public MParameter addNewParameter()
Description copied from interface:MInvokable
Creates a new parameter on this method of type java.lang.Object and with a default name.- Specified by:
addNewParameter
in interfaceMInvokable
-
removeParameter
public void removeParameter(MParameter parameter)
Description copied from interface:MInvokable
Removes the given parameter. Does nothing if the parameter is not present on this method.- Specified by:
removeParameter
in interfaceMInvokable
-
getMutableParameters
public MParameter[] getMutableParameters()
Description copied from interface:MInvokable
Returns all of the parameters on this method, or an empty array if there are none. This is simply a more strongly-typed version of getParameters().- Specified by:
getMutableParameters
in interfaceMInvokable
-
getParameters
public JParameter[] getParameters()
Description copied from interface:JInvokable
Returns representations of the parameters taken by this method. Returns an array of length 0 if the method takes no parameters.
- Specified by:
getParameters
in interfaceJInvokable
-
getExceptionTypes
public JClass[] getExceptionTypes()
Description copied from interface:JInvokable
Returns representations of the type of each of the exceptions which can be thrown by this method. Returns an array of length 0 if the method throws no exceptions.
- Specified by:
getExceptionTypes
in interfaceJInvokable
-
getQualifiedName
public java.lang.String getQualifiedName()
Description copied from interface:JElement
Returns a qualified name for this abstraction. The exact format of this name depends on the particular abstraction. Please refer to the documentation for each JElement subclass for a detailed description of the qualified name formats.
- Specified by:
getQualifiedName
in interfaceJElement
-
setUnqualifiedThrows
public void setUnqualifiedThrows(java.util.List classnames)
-
-