Class BuildExclusionsBuildItem


  • public final class BuildExclusionsBuildItem
    extends io.quarkus.builder.item.SimpleBuildItem
    A type of build item that contains only declaring classes, methods and fields that have been annotated with unsuccessful build time conditions. It aims to be used to manage the exclusion of the annotations thanks to the build time conditions also known as IfBuildProfile, UnlessBuildProfile, IfBuildProperty and UnlessBuildProperty
    See Also:
    io.quarkus.arc.deployment.PreAdditionalBeanBuildTimeConditionBuildItem, IfBuildProfile, UnlessBuildProfile, IfBuildProperty, UnlessBuildProperty
    • Constructor Detail

      • BuildExclusionsBuildItem

        public BuildExclusionsBuildItem​(Set<String> excludedDeclaringClasses,
                                        Set<String> excludedMethods,
                                        Set<String> excludedFields)
    • Method Detail

      • getExcludedDeclaringClasses

        public Set<String> getExcludedDeclaringClasses()
      • getExcludedMethods

        public Set<String> getExcludedMethods()
      • getExcludedFields

        public Set<String> getExcludedFields()
      • isExcluded

        public boolean isExcluded​(org.jboss.jandex.AnnotationTarget target)
        Indicates whether the given target is excluded following the next rules:

        • In case of a class it will check if it is part of the excluded classes
        • In case of a method it will check if it is part of the excluded methods and if its declaring class is excluded
        • In case of a method parameter it will check if its corresponding method is part of the excluded methods and if its declaring class is excluded
        • In case of a field it will check if it is part of the excluded field and if its declaring class is excluded
        • In all other cases, it is not excluded
        Parameters:
        target - the target to check.
        Returns:
        true if the target is excluded, false otherwise.
      • targetMapper

        public static String targetMapper​(org.jboss.jandex.AnnotationTarget target)
        Converts the given target into a String unique representation.
        Parameters:
        target - the target to convert.
        Returns:
        a unique representation as a String of the target