Package net.bytebuddy.matcher
Class StringSetMatcher
- java.lang.Object
-
- net.bytebuddy.matcher.ElementMatcher.Junction.AbstractBase<java.lang.String>
-
- net.bytebuddy.matcher.StringSetMatcher
-
- All Implemented Interfaces:
ElementMatcher<java.lang.String>,ElementMatcher.Junction<java.lang.String>
@Enhance public class StringSetMatcher extends ElementMatcher.Junction.AbstractBase<java.lang.String>
An element matcher which checks if a string is in a set of strings.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.matcher.ElementMatcher
ElementMatcher.Junction<S>
-
Nested classes/interfaces inherited from interface net.bytebuddy.matcher.ElementMatcher.Junction
ElementMatcher.Junction.AbstractBase<V>, ElementMatcher.Junction.Conjunction<W>, ElementMatcher.Junction.Disjunction<W>
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Set<java.lang.String>valuesThe values to check against.
-
Constructor Summary
Constructors Constructor Description StringSetMatcher(java.util.Set<java.lang.String> values)Creates a new string set matcher.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanmatches(java.lang.String target)Matches a target against this element matcher.java.lang.StringtoString()-
Methods inherited from class net.bytebuddy.matcher.ElementMatcher.Junction.AbstractBase
and, or
-
-
-
-
Method Detail
-
matches
public boolean matches(java.lang.String target)
Description copied from interface:ElementMatcherMatches a target against this element matcher.- Parameters:
target- The instance to be matched.- Returns:
trueif the given element is matched by this matcher orfalseotherwise.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-