Top Description Methods
jakarta.enterprise.inject.build.compatible.spi

public Interface ParameterConfig

extends DeclarationConfig
Imports
java.lang.annotation.Annotation, java.util.function.Predicate, jakarta.enterprise.lang.model.AnnotationInfo, jakarta.enterprise.lang.model.declarations.ParameterInfo

Allows adding annotations to and removing annotations from a method parameter. Note that the method parameter is not physically altered, the modifications are only seen by the CDI container.
Since
4.0
See Also
Enhancement

Method Summary

Modifier and TypeMethod and Description
public ParameterConfig

Returns:

this configurator object, to allow fluent usage
addAnnotation
(Class<? extends Annotation>
the annotation type, must not be null
annotationType
)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds a marker annotation of given type to this method parameter.

public ParameterConfig

Returns:

this configurator object, to allow fluent usage
addAnnotation
(AnnotationInfo
the annotation to add to this method parameter, must not be null
annotation
)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds given annotation to this method parameter.

public ParameterConfig

Returns:

this configurator object, to allow fluent usage
addAnnotation
(Annotation
the annotation to add to this method parameter, must not be null
annotation
)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds given annotation to this method parameter.

public ParameterInfo

Returns:

the ParameterInfo corresponding to this transformed method parameter, never null
info
()

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.info.

Returns the ParameterInfo corresponding to this transformed method parameter.

public ParameterConfig

Returns:

this configurator object, to allow fluent usage
removeAllAnnotations
()

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.removeAllAnnotations.

Removes all annotations from this method parameter.

public ParameterConfig

Returns:

this configurator object, to allow fluent usage
removeAnnotation
(Predicate<AnnotationInfo>
an annotation predicate, must not be null
predicate
)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.removeAnnotation.

Removes all annotations matching given predicate from this method parameter.

Method Detail

addAnnotationback to summary
public ParameterConfig addAnnotation(Class<? extends Annotation> annotationType)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds a marker annotation of given type to this method parameter. Does not allow configuring annotation members.

Parameters
annotationType:Class<? extends Annotation>

the annotation type, must not be null

Returns:ParameterConfig

this configurator object, to allow fluent usage

Annotations
@Override
addAnnotationback to summary
public ParameterConfig addAnnotation(AnnotationInfo annotation)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds given annotation to this method parameter. The AnnotationInfo can be obtained from an annotation target, or constructed from scratch using AnnotationBuilder.

Parameters
annotation:AnnotationInfo

the annotation to add to this method parameter, must not be null

Returns:ParameterConfig

this configurator object, to allow fluent usage

Annotations
@Override
addAnnotationback to summary
public ParameterConfig addAnnotation(Annotation annotation)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.addAnnotation.

Adds given annotation to this method parameter. The annotation instance is typically a subclass of AnnotationLiteral.

Parameters
annotation:Annotation

the annotation to add to this method parameter, must not be null

Returns:ParameterConfig

this configurator object, to allow fluent usage

Annotations
@Override
infoback to summary
public ParameterInfo info()

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.info.

Returns the ParameterInfo corresponding to this transformed method parameter.

Returns:ParameterInfo

the ParameterInfo corresponding to this transformed method parameter, never null

Annotations
@Override
removeAllAnnotationsback to summary
public ParameterConfig removeAllAnnotations()

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.removeAllAnnotations.

Removes all annotations from this method parameter.

Returns:ParameterConfig

this configurator object, to allow fluent usage

Annotations
@Override
removeAnnotationback to summary
public ParameterConfig removeAnnotation(Predicate<AnnotationInfo> predicate)

Redeclares jakarta.enterprise.inject.build.compatible.spi.DeclarationConfig.removeAnnotation.

Removes all annotations matching given predicate from this method parameter.

Parameters
predicate:Predicate<AnnotationInfo>

an annotation predicate, must not be null

Returns:ParameterConfig

this configurator object, to allow fluent usage

Annotations
@Override