public class PatternMatchedCollection<T> extends Object implements TargetTranslatable<PatternMatchedCollection<T>>
Modifier and Type | Class and Description |
---|---|
static class |
PatternMatchedCollection.Builder<T> |
Modifier and Type | Method and Description |
---|---|
static <T> PatternMatchedCollection.Builder<T> |
builder() |
static <T> PatternMatchedCollection<T> |
concat(Iterable<PatternMatchedCollection<T>> collections) |
boolean |
equals(Object o) |
void |
forEachMatchingValue(String string,
java.util.function.Consumer<T> consumer)
|
void |
forEachValue(java.util.function.Consumer<T> consumer)
Apply
consumer to all values. |
com.google.common.collect.ImmutableList<T> |
getMatchingValues(String string) |
com.google.common.collect.ImmutableList<Pair<Pattern,T>> |
getPatternsAndValues() |
com.google.common.collect.ImmutableList<T> |
getValues() |
int |
hashCode() |
<V> PatternMatchedCollection<V> |
map(java.util.function.Function<T,V> func) |
static <T> PatternMatchedCollection<T> |
of() |
Optional<PatternMatchedCollection<T>> |
translateTargets(CellNameResolver cellPathResolver,
BaseName targetBaseName,
TargetNodeTranslator translator) |
public void forEachMatchingValue(String string, java.util.function.Consumer<T> consumer)
public com.google.common.collect.ImmutableList<T> getMatchingValues(String string)
Pattern
matches string
.public com.google.common.collect.ImmutableList<Pair<Pattern,T>> getPatternsAndValues()
public void forEachValue(java.util.function.Consumer<T> consumer)
consumer
to all values.public com.google.common.collect.ImmutableList<T> getValues()
public Optional<PatternMatchedCollection<T>> translateTargets(CellNameResolver cellPathResolver, BaseName targetBaseName, TargetNodeTranslator translator)
translateTargets
in interface TargetTranslatable<PatternMatchedCollection<T>>
public static <T> PatternMatchedCollection<T> of()
public <V> PatternMatchedCollection<V> map(java.util.function.Function<T,V> func)
public static <T> PatternMatchedCollection<T> concat(Iterable<PatternMatchedCollection<T>> collections)
PatternMatchedCollection
formed by combining the given input PatternMatchedCollection
s.public static <T> PatternMatchedCollection.Builder<T> builder()