|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.biojava.bio.program.tagvalue.RegexSplitter
public class RegexSplitter
A ValueChanger.Splitter that splits a line of text using a regular expression, returning one value per match.
A list of values is generated by effectively executing:
matcher = pattern.matcher(value.toString());
while(matcher.find()) {
values.add(matcher.group(matchGroup);
}
| Constructor Summary | |
|---|---|
RegexSplitter(Pattern pattern,
int matchGroup)
Create a new RegexSplitter with a pattern. |
|
| Method Summary | |
|---|---|
List |
split(Object value)
Produce a list of values from an old value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RegexSplitter(Pattern pattern,
int matchGroup)
pattern - the Pattern used to split valuesmatchGroup - the group to pull out - use 0 to pull out the whole match| Method Detail |
|---|
public List split(Object value)
ChangeTable.SplitterProduce a list of values from an old value.
It is strongly recommended that this method is re-entrant and does not modify the state of the Splitter in a way that would affect future return -values.
split in interface ChangeTable.Splittervalue - the old value Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||