public class RegExParser extends Object implements SerialDataParser
Constructor and Description |
---|
RegExParser(String regex)
Construct a new regex parser
|
Modifier and Type | Method and Description |
---|---|
String |
getLeftOverString()
This function must return the data that was left-over
from the previous parse, if at all.
|
String[] |
parse(String data)
Called to parse the raw data into tokens or sentences.
|
void |
setRegEx(String regex)
Set the regular expression to use.
|
public RegExParser(String regex)
regex
- public String[] parse(String data)
parse
in interface SerialDataParser
data
- The raw data.SerialDataParser.parse(java.lang.String)
public String getLeftOverString()
getLeftOverString
in interface SerialDataParser
SerialDataParser.getLeftOverString()