|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--org.apache.commons.lang.CharSetUtils
Numerous routines to manipulate a character set.
| Constructor Summary | |
CharSetUtils()
CharSetUtils instances should NOT be constructed in standard programming. |
|
| Method Summary | |
static int |
count(java.lang.String str,
java.lang.String set)
Takes an argument in set-syntax, see evaluateSet, and returns the number of characters present in the specified string. |
static int |
count(java.lang.String str,
java.lang.String[] set)
Takes an argument in set-syntax, see evaluateSet, and returns the number of characters present in the specified string. |
static java.lang.String |
delete(java.lang.String str,
java.lang.String set)
Takes an argument in set-syntax, see evaluateSet, and deletes any of characters present in the specified string. |
static java.lang.String |
delete(java.lang.String str,
java.lang.String[] set)
Takes an argument in set-syntax, see evaluateSet, and deletes any of characters present in the specified string. |
static CharSet |
evaluateSet(java.lang.String[] set)
Creates a CharSetUtils object which allows a certain amount of set logic to be performed upon the following syntax: "aeio" which implies 'a','e',.. |
static java.lang.String |
squeeze(java.lang.String str,
java.lang.String set)
Squeezes any repititions of a character that is mentioned in the supplied set. |
static java.lang.String |
squeeze(java.lang.String str,
java.lang.String[] set)
Squeezes any repititions of a character that is mentioned in the supplied set. |
static java.lang.String |
translate(java.lang.String target,
java.lang.String repl,
java.lang.String with)
Translate characters in a String. |
| Methods inherited from class java.lang.Object |
|
| Constructor Detail |
public CharSetUtils()
CharSetUtils.evaluateSet(null);.
This constructor is public to permit tools that require a JavaBean instance
to operate.| Method Detail |
public static CharSet evaluateSet(java.lang.String[] set)
set - set - NullPointerException - if any of set[i] is null or if set is null
public static java.lang.String squeeze(java.lang.String str,
java.lang.String set)
str - the string to work fromset - the character set to use for manipulation
public static java.lang.String squeeze(java.lang.String str,
java.lang.String[] set)
str - the string to work fromset - the character set to use for manipulationNullPointerException - if str is null
public static int count(java.lang.String str,
java.lang.String set)
str - String target to count characters inset - String set of characters to count
public static int count(java.lang.String str,
java.lang.String[] set)
str - String target to count characters inset - String[] set of characters to count
public static java.lang.String delete(java.lang.String str,
java.lang.String set)
str - String target to delete characters fromset - String set of characters to delete
public static java.lang.String delete(java.lang.String str,
java.lang.String[] set)
str - String target to delete characters fromset - String[] set of characters to deleteNullPointerException - of str is null
public static java.lang.String translate(java.lang.String target,
java.lang.String repl,
java.lang.String with)
target - String to replace characters inrepl - String to find that will be replacedwith - String to put into the target StringNullPointerException - if target, with or repl is null
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||