org.apache.cocoon.util
Class StringUtils

java.lang.Object
  extended byorg.apache.cocoon.util.StringUtils

public class StringUtils
extends Object

A collection of String handling utility methods.

Version:
CVS $Id: StringUtils.java 30941 2004-07-29 19:56:58Z vgritsenko $
Author:
Ricardo Rocha, Stefano Mazzocchi

Constructor Summary
StringUtils()
           
 
Method Summary
static boolean isAlphaNumeric(char c)
          Tests whether a given character is alphabetic, numeric or underscore
static String replaceToken(String s)
          Replaces tokens in input with Value present in System.getProperty
static String[] split(String line)
          Split a string as an array using whitespace as separator
static String[] split(String line, String delimiter)
          Split a string as an array using a given set of separators
 
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

split

public static String[] split(String line)
Split a string as an array using whitespace as separator

Parameters:
line - The string to be split
Returns:
An array of whitespace-separated tokens

split

public static String[] split(String line,
                             String delimiter)
Split a string as an array using a given set of separators

Parameters:
line - The string to be split
delimiter - A string containing token separators
Returns:
An array of token

isAlphaNumeric

public static boolean isAlphaNumeric(char c)
Tests whether a given character is alphabetic, numeric or underscore

Parameters:
c - The character to be tested
Returns:
whether the given character is alphameric or not

replaceToken

public static String replaceToken(String s)
Replaces tokens in input with Value present in System.getProperty



Copyright ? 1999-2005 The Apache Software Foundation. All Rights Reserved.