Class KotlinMetadataVersionFilter
- java.lang.Object
-
- proguard.classfile.kotlin.visitor.KotlinMetadataVersionFilter
-
- All Implemented Interfaces:
AnnotationVisitor
,ElementValueVisitor
,ClassVisitor
public class KotlinMetadataVersionFilter extends java.lang.Object implements ClassVisitor, AnnotationVisitor, ElementValueVisitor
Tests a predicate on the classes' KotlinMetadataVersion and delegates to different ClassVisitors based on the result.
-
-
Constructor Summary
Constructors Constructor Description KotlinMetadataVersionFilter(java.util.function.Predicate<KotlinMetadataVersion> predicate, ClassVisitor accepted, ClassVisitor rejected)
Tests a predicate on the classes' KotlinMetadataVersion and delegates to different ClassVisitors based on the result.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
visitAnnotation(Clazz clazz, Annotation annotation)
Visits any Annotation instance.void
visitAnyClass(Clazz clazz)
Visits any Clazz instance.void
visitAnyElementValue(Clazz clazz, Annotation annotation, ElementValue elementValue)
Visits any ElementValue instance.void
visitArrayElementValue(Clazz clazz, Annotation annotation, ArrayElementValue arrayElementValue)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface proguard.classfile.attribute.annotation.visitor.AnnotationVisitor
visitAnnotation, visitAnnotation, visitAnnotation, visitAnnotation, visitAnnotation
-
Methods inherited from interface proguard.classfile.visitor.ClassVisitor
visitLibraryClass, visitProgramClass
-
Methods inherited from interface proguard.classfile.attribute.annotation.visitor.ElementValueVisitor
visitAnnotationElementValue, visitClassElementValue, visitConstantElementValue, visitEnumConstantElementValue
-
-
-
-
Constructor Detail
-
KotlinMetadataVersionFilter
public KotlinMetadataVersionFilter(java.util.function.Predicate<KotlinMetadataVersion> predicate, ClassVisitor accepted, ClassVisitor rejected)
Tests a predicate on the classes' KotlinMetadataVersion and delegates to different ClassVisitors based on the result.- Parameters:
predicate
- The predicate to test the KotlinMetadata againstaccepted
- The ClassVisitor to delegate to iff predicate.testrejected
- The ClassVisitor to delegate to iff !predicate.test
-
-
Method Detail
-
visitAnyClass
public void visitAnyClass(Clazz clazz)
Description copied from interface:ClassVisitor
Visits any Clazz instance. The more specific default implementations of this interface delegate to this method.- Specified by:
visitAnyClass
in interfaceClassVisitor
-
visitAnnotation
public void visitAnnotation(Clazz clazz, Annotation annotation)
Description copied from interface:AnnotationVisitor
Visits any Annotation instance. The more specific default implementations of this interface delegate to this method.- Specified by:
visitAnnotation
in interfaceAnnotationVisitor
-
visitAnyElementValue
public void visitAnyElementValue(Clazz clazz, Annotation annotation, ElementValue elementValue)
Description copied from interface:ElementValueVisitor
Visits any ElementValue instance. The more specific default implementations of this interface delegate to this method.- Specified by:
visitAnyElementValue
in interfaceElementValueVisitor
-
visitArrayElementValue
public void visitArrayElementValue(Clazz clazz, Annotation annotation, ArrayElementValue arrayElementValue)
- Specified by:
visitArrayElementValue
in interfaceElementValueVisitor
-
-