OSMQ
v2.0.1

osmq.util
Class StringParser

java.lang.Object
  extended byosmq.util.StringParser

public class StringParser
extends java.lang.Object


Constructor Summary
StringParser(java.lang.String string)
           
 
Method Summary
 boolean findSubstring(java.lang.String sub)
           
 boolean findTokenOccurance(char token, int occurance)
          Locates an occurance of a character within a string and returns its offset.
 boolean findTokenOccurance(java.lang.String token, int occurance)
          Locates an occurance of a character within a string that matches a character in another string, and returns its offset.
 int getOccurance()
           
 int getPosition()
           
 boolean ignoreSubstring(java.lang.String sub)
           
 void resetPosition()
           
 boolean validString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringParser

public StringParser(java.lang.String string)
Method Detail

getPosition

public final int getPosition()

validString

public boolean validString()

getOccurance

public int getOccurance()

findSubstring

public final boolean findSubstring(java.lang.String sub)

ignoreSubstring

public final boolean ignoreSubstring(java.lang.String sub)

findTokenOccurance

public final boolean findTokenOccurance(java.lang.String token,
                                        int occurance)
Locates an occurance of a character within a string that matches a character in another string, and returns its offset. The occurances are numbered 1-n. If the occurance is not found, returns -1. If found, returns the zero-relative offset position of the character.


resetPosition

public void resetPosition()

findTokenOccurance

public final boolean findTokenOccurance(char token,
                                        int occurance)
Locates an occurance of a character within a string and returns its offset. The occurances are numbered 1-n. If the occurance is not found, returns -1. If found, returns the zero-relative offset position of the character.


(c) 2000 - 2003 MQue Systems
All Rights Reserved