antlr
Class StringUtils

java.lang.Object
  |
  +--antlr.StringUtils

public class StringUtils
extends Object


Constructor Summary
StringUtils()
           
 
Method Summary
static String stripBack(String s, char c)
          General-purpose utility function for removing characters from back of string
static String stripBack(String s, String remove)
          General-purpose utility function for removing characters from back of string
static String stripFront(String s, char c)
          General-purpose utility function for removing characters from front of string
static String stripFront(String s, String remove)
          General-purpose utility function for removing characters from front of string
static String stripFrontBack(String src, String head, String tail)
          General-purpose utility function for removing characters from the front and back of string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringUtils

public StringUtils()
Method Detail

stripBack

public static String stripBack(String s,
                               char c)
General-purpose utility function for removing characters from back of string

Parameters:
s - The string to process
c - The character to remove
Returns:
The resulting string

stripBack

public static String stripBack(String s,
                               String remove)
General-purpose utility function for removing characters from back of string

Parameters:
s - The string to process
remove - A string containing the set of characters to remove
Returns:
The resulting string

stripFront

public static String stripFront(String s,
                                char c)
General-purpose utility function for removing characters from front of string

Parameters:
s - The string to process
c - The character to remove
Returns:
The resulting string

stripFront

public static String stripFront(String s,
                                String remove)
General-purpose utility function for removing characters from front of string

Parameters:
s - The string to process
remove - A string containing the set of characters to remove
Returns:
The resulting string

stripFrontBack

public static String stripFrontBack(String src,
                                    String head,
                                    String tail)
General-purpose utility function for removing characters from the front and back of string

Parameters:
head - exact string to strip from head
tail - exact string to strip from tail
Returns:
The resulting string


Copyright © 1999-2003 Oliver Zeigermann. All Rights Reserved.