|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectplanetj.util.CasedStringBuffer
StringBuffer substitute which has special methods for working with mixed case Strings
Constructor Summary | |
CasedStringBuffer(int initialCapacity)
Creates a new CasedStringBuffer with the specified initial capacity |
|
CasedStringBuffer(java.lang.String initialString)
Creates a new CasedStringBuffer with the specified initial String |
Method Summary | |
CasedStringBuffer |
append(java.lang.String s)
Appends a String |
char |
charAt(int pos)
Gets the character (upper or lower case) at the specified position |
int |
indexOf(java.lang.String s)
Gets the first index at which a String occurs in this CasedStringBuffer. |
int |
indexOf(java.lang.String s,
boolean ignoreSingleQuoted)
Gets the first index at which a String occurs in this CasedStringBuffer. |
int |
indexOf(java.lang.String s,
int startingPos)
Gets the first index at which a String occurs in this CasedStringBuffer, starting at a specified search index. |
int |
indexOf(java.lang.String s,
int startingPos,
boolean ignoreSingleQuoted)
Gets the first index at which a String occurs in this CasedStringBuffer, starting at a specified search index. |
CasedStringBuffer |
insert(int pos,
java.lang.String s)
Inserts a String into this CasedStringBuffer |
int |
length()
Gets the number of characters in this CasedStringBuffer |
char |
lowerCaseCharAt(int pos)
Gets the character (converted to lower case) at the specified position |
CasedStringBuffer |
replace(int start,
int end,
java.lang.String s)
Replaces a range of characters in this CasedStringBuffer with a specified String |
java.lang.String |
substring(int beginIndex)
Returns a new String which is a substring of this CasedStringBuffer |
java.lang.String |
substring(int beginIndex,
int endIndex)
Returns a new String which is a substring of this CasedStringBuffer |
java.lang.String |
toLowerCaseString()
Converts this CasedStringBuffer into a String (which will only contain lower case chars) |
java.lang.String |
toString()
Converts this CasedStringBuffer into a String (which could contain upper and lower case chars) |
java.lang.String |
toUpperCaseString()
Converts this CasedStringBuffer into a String (which will only contain upper case chars) |
char |
upperCaseCharAt(int pos)
Gets the character (converted to upper case) at the specified position |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public CasedStringBuffer(java.lang.String initialString)
public CasedStringBuffer(int initialCapacity)
Method Detail |
public CasedStringBuffer append(java.lang.String s)
public char charAt(int pos)
public int indexOf(java.lang.String s)
s
- The String to look forpublic int indexOf(java.lang.String s, boolean ignoreSingleQuoted)
s
- The String to look forignoreSingleQuoted
- When true, portions of the string which are between single quotes (including the single quote themselves)
are not included in the index searchpublic int indexOf(java.lang.String s, int startingPos)
s
- The String to look forstartingPos
- The index where the search beginspublic int indexOf(java.lang.String s, int startingPos, boolean ignoreSingleQuoted)
s
- The String to look forstartingPos
- The index where the search beginsignoreSingleQuoted
- When true, portions of the string which are between single quotes (including the single quotes themselves)
are not included in the index searchpublic CasedStringBuffer insert(int pos, java.lang.String s)
pos
- The position of the first character to be inserteds
- The replacement Stringpublic int length()
public char lowerCaseCharAt(int pos)
public CasedStringBuffer replace(int start, int end, java.lang.String s)
start
- The position of the first character to be replacedend
- The position of the character right after the last character to be replaceds
- The replacement Stringpublic java.lang.String substring(int beginIndex)
beginIndex
- The index of the first character in the substring. (The substring extends to
the end of the characters in this CasedStringBuffer.)public java.lang.String substring(int beginIndex, int endIndex)
beginIndex
- The index of the first character in the substringendIndex
- One more than the index of the last character in the substringpublic java.lang.String toLowerCaseString()
public java.lang.String toString()
public java.lang.String toUpperCaseString()
public char upperCaseCharAt(int pos)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |