to.etc.util
Class CmdStringDecoder

java.lang.Object
  extended by to.etc.util.CmdStringDecoder

public class CmdStringDecoder
extends java.lang.Object

This class helps decoding command lines where a command line is a string. It parses the string and generates a string array from all it's components, then it is able to ask all kinds of questions about the string. It accepts quoted arguments and presents them as a whole as one argument. The principal use of this class is from within the TelnetServer where it is used to parse Telnet commands.

Author:
Frits Jalvingh

Constructor Summary
CmdStringDecoder(java.lang.String cmd)
           
 
Method Summary
 int currInt()
           
 boolean currIs(java.lang.String txt)
          Returns T if the current part is...
 boolean currIsInt()
           
 java.lang.String getCurr()
           
 java.lang.String getNext()
           
 boolean hasMore()
           
 void reset()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CmdStringDecoder

public CmdStringDecoder(java.lang.String cmd)
Method Detail

hasMore

public boolean hasMore()

reset

public void reset()

getCurr

public java.lang.String getCurr()

getNext

public java.lang.String getNext()

currIs

public boolean currIs(java.lang.String txt)
Returns T if the current part is...


currInt

public int currInt()

currIsInt

public boolean currIsInt()