org.ourgrid.common.util
Class OGStringTokenizer

java.lang.Object
  extended by org.ourgrid.common.util.OGStringTokenizer

public class OGStringTokenizer
extends java.lang.Object

Similar to StringTokenizer, but not brokes the tokens using the internal deliimiters characters only uses the full delimiter.


Constructor Summary
OGStringTokenizer(java.lang.String string, java.lang.String delim)
          Creates an new OGTokenizer
 
Method Summary
 int countTokens()
          The number of tokens in the token list.
 boolean hasMoreTokens()
          Verifies if has more tokens in tokens list.
 java.lang.String nextToken()
          Consumes the first token of token list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OGStringTokenizer

public OGStringTokenizer(java.lang.String string,
                         java.lang.String delim)
Creates an new OGTokenizer

Parameters:
string - The string to tokenize
delim - The delimiter
Method Detail

hasMoreTokens

public boolean hasMoreTokens()
Verifies if has more tokens in tokens list.

Returns:
true if hasmore tokens in the tokens list, false otherwise

countTokens

public int countTokens()
The number of tokens in the token list.

Returns:
The number of tokens in the token list.

nextToken

public java.lang.String nextToken()
Consumes the first token of token list.

Returns:
The first token of token list.