cz.cuni.amis.utils
Class StringCutter

java.lang.Object
  extended by cz.cuni.amis.utils.StringCutter

public class StringCutter
extends java.lang.Object

You will stuff strings into the object and it will check whether the 'limiter' is present. If so, it will cut the string buffer along the 'limiter' and return you the parts.


Constructor Summary
StringCutter()
          Default limiter is "\r\n" (windows new line).
StringCutter(java.lang.String limiter)
           
 
Method Summary
 java.lang.String[] add(java.lang.String str)
          Adding string to the buffer, returning strings if 'limiter' is found.
 void clear()
          Clear the string buffer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringCutter

public StringCutter()
Default limiter is "\r\n" (windows new line).


StringCutter

public StringCutter(java.lang.String limiter)
Method Detail

add

public java.lang.String[] add(java.lang.String str)
Adding string to the buffer, returning strings if 'limiter' is found. If no limiter is present, returns String[0].

Parameters:
str -
Returns:

clear

public void clear()
Clear the string buffer.