Interface MethodCreator
- All Superinterfaces:
AnnotatableCreator, ExecutableCreator, MemberCreator, MethodTyped, ModifiableCreator, Typed, TypeParameterizedCreator
- All Known Subinterfaces:
AbstractMethodCreator, InstanceMethodCreator, StaticMethodCreator
public sealed interface MethodCreator
extends ExecutableCreator, MemberCreator
permits AbstractMethodCreator, InstanceMethodCreator, StaticMethodCreator (not exhaustive)
A creator for any kind of method on a class.
-
Method Summary
Modifier and TypeMethodDescriptiondesc()Returns the descriptor of the method.voidreturning(GenericType type) Change the generic return type of this method.default voidChange the return type of this method.voidChange the return type of this method.default voidAdd thesynchronizedmodifier flag to this creator.Methods inherited from interface AnnotatableCreator
addAnnotation, addAnnotation, addAnnotation, addAnnotationMethods inherited from interface ExecutableCreator
parameter, parameter, parameter, parameter, parameter, parameter, parameter, parameter, parameter, parameter, setType, throws_, throws_, throws_, type, varargsMethods inherited from interface MemberCreator
name, owner, typeMethods inherited from interface MethodTyped
genericReturnType, hasGenericReturnType, isPrimitiveParameter, isPrimitiveReturn, isVoidReturn, parameterCount, parameterSlotSize, parameterType, parameterTypeKind, parameterTypes, returnSlotSize, returnType, returnTypeKindMethods inherited from interface ModifiableCreator
addFlag, addFlags, addFlags, final_, modifierLocation, packagePrivate, private_, protected_, public_, removeFlag, removeFlags, removeFlags, setAccess, supports, syntheticMethods inherited from interface TypeParameterizedCreator
typeParameter, typeParameter
-
Method Details
-
desc
MethodDesc desc()Returns the descriptor of the method.- Specified by:
descin interfaceMemberCreator- Returns:
- the descriptor of the method
-
returning
Change the generic return type of this method. The method type is changed with the new return type.- Parameters:
type- the generic return type (must not benull)
-
returning
Change the return type of this method. The method type is changed with the new return type.- Parameters:
type- the descriptor of the return type (must not benull)
-
returning
Change the return type of this method. The method type is changed with the new return type.- Parameters:
type- the return type (must not benull)
-
synchronized_
default void synchronized_()Add thesynchronizedmodifier flag to this creator.- Throws:
IllegalArgumentException- if this creator does not support thesynchronizedmodifier flag
-