public class ArgumentTokenizer extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
ArgumentTokenizer.ArgumentException |
| Modifier and Type | Field and Description |
|---|---|
protected int |
currentPosition |
protected int |
maxPosition |
protected String |
str |
protected StringBuilder |
token |
| Constructor and Description |
|---|
ArgumentTokenizer(String str)
Construct a tokenizer for the specified string.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasMoreTokens()
Test if there are more tokens available from this tokenizer's string.
|
String |
nextToken()
Return the next token from this tokenizer.
|
protected String |
scanToken()
Return the next token starting at the current position,
assuming whitespace has already been skipped.
|
protected void |
skipWhiteSpace()
Skip white space.
|
protected int currentPosition
protected int maxPosition
protected String str
protected StringBuilder token
public ArgumentTokenizer(String str)
str - a string to be parsed.protected void skipWhiteSpace()
public boolean hasMoreTokens()
true if there are more tokens available from this
tokenizer's string; false otherwise.public String nextToken() throws ArgumentTokenizer.ArgumentException
NoSuchElementException - if there are no more tokens in this
tokenizer's string.ArgumentTokenizer.ArgumentExceptionprotected String scanToken() throws ArgumentTokenizer.ArgumentException
Copyright © 2017–2019 Eclipse Foundation. All rights reserved.