public class InvariantsMapper extends java.lang.Object implements org.apache.commons.collections4.Transformer<ParikhVector,java.util.List<java.lang.Integer>>
| Constructor and Description |
|---|
InvariantsMapper(java.util.Set<java.lang.String> alphabet,
java.util.Collection<java.util.List<java.lang.String>> invariantWords)
Define an invariant mapper over the given alphabet with the given words being invariant.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.List<java.lang.Integer> |
transform(ParikhVector pv) |
public InvariantsMapper(java.util.Set<java.lang.String> alphabet,
java.util.Collection<java.util.List<java.lang.String>> invariantWords)
ParikhVectors that should later be mapped must be over the given alphabet. For example, with the only
invariant being "a","b", the words "c" and "a","c","b" will be mapped to the equal results.alphabet - The alphabet over which Parikh vectors will be given.invariantWords - A collection of words which should be invariant.public java.util.List<java.lang.Integer> transform(ParikhVector pv)
transform in interface org.apache.commons.collections4.Transformer<ParikhVector,java.util.List<java.lang.Integer>>