- All Superinterfaces:
AnnotatableCreator
- All Known Subinterfaces:
AbstractMethodCreator,AnonymousClassCreator,ClassCreator,ConstructorCreator,ExecutableCreator,FieldCreator,InstanceExecutableCreator,InstanceFieldCreator,InstanceMethodCreator,InterfaceCreator,MemberCreator,MethodCreator,ParamCreator,StaticExecutableCreator,StaticFieldCreator,StaticMethodCreator,TypeCreator
public sealed interface ModifiableCreator
extends AnnotatableCreator
permits ExecutableCreator, MemberCreator, ParamCreator, TypeCreator (not exhaustive)
A creator for something which can have modifiers.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddFlag(ModifierFlag flag) Add the given modifier flag to this creator.default voidaddFlags(ModifierFlag... flags) Add the given modifier flags to this creator.default voidaddFlags(Collection<ModifierFlag> flags) Add the given modifier flags to this creator.default voidfinal_()Add thefinalmodifier flag to this creator.Returns the modifier location constant for this creator (notnull).default voidSet the access level of this creator to package-private.default voidprivate_()Set the access level of this creator toprivate.default voidSet the access level of this creator toprotected.default voidpublic_()Set the access level of this creator topublic.voidremoveFlag(ModifierFlag flag) Remove the given modifier flag from this creator.default voidremoveFlags(ModifierFlag... flags) Remove the given modifier flags from this creator.default voidremoveFlags(Collection<ModifierFlag> flags) Remove the given modifier flags from this creator.voidsetAccess(AccessLevel access) Set the access level of this creator.default booleanReturnstrueif the given modifier is supported by this creator, orfalseif it is not.default voidAdd the "synthetic" modifier flag to this creator.Methods inherited from interface io.quarkus.gizmo2.creator.AnnotatableCreator
addAnnotation, addAnnotation, addAnnotation, addAnnotation
-
Method Details
-
modifierLocation
ModifierLocation modifierLocation()Returns the modifier location constant for this creator (notnull).- Returns:
- the modifier location constant for this creator (not
null)
-
addFlag
Add the given modifier flag to this creator.- Parameters:
flag- the flag to add (must not benull)- Throws:
IllegalArgumentException- if this creator does not support the given flag
-
addFlags
Add the given modifier flags to this creator.- Parameters:
flags- the flags to add (must not benull)- Throws:
IllegalArgumentException- if this creator does not support one of the given flags
-
addFlags
Add the given modifier flags to this creator.- Parameters:
flags- the flags to add (must not benull)- Throws:
IllegalArgumentException- if this creator does not support one of the given flags
-
removeFlag
Remove the given modifier flag from this creator.- Parameters:
flag- the flag to remove (must not benull)- Throws:
IllegalArgumentException- if this creator does not support the given flag
-
removeFlags
Remove the given modifier flags from this creator.- Parameters:
flags- the flags to remove (must not benull)- Throws:
IllegalArgumentException- if this creator does not support one of the given flags
-
removeFlags
Remove the given modifier flags from this creator.- Parameters:
flags- the flags to remove (must not benull)- Throws:
IllegalArgumentException- if this creator does not support one of the given flags
-
supports
Returnstrueif the given modifier is supported by this creator, orfalseif it is not.- Parameters:
modifier- the modifier to test (must not benull)- Returns:
trueif the given modifier is supported by this creator, orfalseif it is not
-
setAccess
Set the access level of this creator.- Parameters:
access- the access level to set (must not benull)- Throws:
IllegalArgumentException- if this creator does not support the given access level
-
public_
default void public_()Set the access level of this creator topublic.- Throws:
IllegalArgumentException- if this creator does not support thepublicaccess level
-
protected_
default void protected_()Set the access level of this creator toprotected.- Throws:
IllegalArgumentException- if this creator does not support theprotectedaccess level
-
packagePrivate
default void packagePrivate()Set the access level of this creator to package-private.- Throws:
IllegalArgumentException- if this creator does not support the package-private access level
-
private_
default void private_()Set the access level of this creator toprivate.- Throws:
IllegalArgumentException- if this creator does not support theprivateaccess level
-
final_
default void final_()Add thefinalmodifier flag to this creator.- Throws:
IllegalArgumentException- if this creator does not support thefinalmodifier flag
-
synthetic
default void synthetic()Add the "synthetic" modifier flag to this creator.- Throws:
IllegalArgumentException- if this creator does not support the "synthetic" modifier flag
-