xbn.string
Class UtilStringBuffer

java.lang.Object
  |
  +--xbn.XBNObject
        |
        +--xbn.string.UtilSOB
              |
              +--xbn.string.UtilStringBuffer

public class UtilStringBuffer
extends UtilSOB

Random functions for java.lang.StringBuffers. See StringBuffer.

Source code:  UtilStringBuffer.java.  Unit tests:  See the unit tests for UtilSOB.


Field Summary
static String sUSB
          To shorten code and Javadoc.
 
Fields inherited from class xbn.string.UtilSOB
sUSOB
 
Fields inherited from class xbn.XBNObject
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP
 
Constructor Summary
UtilStringBuffer()
          Create a UtilStringBuffer.
 
Method Summary
 void dupAppend(StringBuffer str_buffer, String s_toDuplicate, int i_dupCount)
          Append a duplicated string onto the StringBuffer.
 SOBString[] getAOSOBS(StringBuffer[] a_stringBuffer)
          Get an array of SOBStrings from the array of StringBuffers.
 SOBStringBuffer[] getAOSOBSB(StringBuffer[] a_stringBuffer)
          Get an array of SOBStringBuffers from the array of StringBuffers.
 StringBuffer getDupAppend(StringBuffer str_buffer, String s_toDuplicate, int i_dupCount)
          Get a copy of the StringBuffer, after appending a duplicated string onto it.
 int getIdxOf1stCharNIA(StringBuffer str_buffer, char[] a_char)
          Get the array index of the first character that is not a member of the array.
 int getIdxOf1stCharNIA(StringBuffer str_buffer, char[] a_char, boolean b_validateAOC)
          Get the array index of the first character that is not a member of the array.
 int getIdxOf1stCharNIA(StringBuffer str_buffer, char[] a_char, int i_idxStart, int i_idxAfterEnd)
          Get the array index of the first character that is not a member of the array.
 int getIdxOf1stCharNIA(StringBuffer str_buffer, char[] a_char, int i_idxStart, int i_idxAfterEnd, boolean b_validateAOC)
          Get the array index of the first character that does not exist in the array.
 int getIdxOf1stNonWS(StringBuffer str_buffer)
          Get the array index of the first non-white-space character.
 int getIdxOfLastCharNIA(StringBuffer str_buffer, char[] a_char)
          Get the array index of the last character that is not a member of the array.
 int getIdxOfLastCharNIA(StringBuffer str_buffer, char[] a_char, boolean b_validateAOC)
          Get the array index of the last character that is not a member of the array.
 int getIdxOfLastCharNIA(StringBuffer str_buffer, char[] a_char, int i_idxStart, int i_idxAfterEnd)
          Get the array index of the last character that is not a member of the array.
 int getIdxOfLastCharNIA(StringBuffer str_buffer, char[] a_char, int i_idxStart, int i_idxAfterEnd, boolean b_validateAOC)
          Get the array index of the last character that does not exist in the array.
 int getIdxOfLastNonWS(StringBuffer str_buffer)
          Get the array index of the last non-white-space character.
 StringBuffer getQuotedLines(StringBuffer str_buffer)
          Get a copy of the StringBuffer where each line is quoted.
 StringBuffer getQuotedLines(StringBuffer str_buffer, String s_quote)
          Get a copy of the StringBuffer where each line is quoted.
 StringBuffer getQuotedLines(StringBuffer str_buffer, String s_quoteStart, String s_quoteEnd)
          Get a copy of the StringBuffer where each line is quoted.
 StringBuffer getQuotedLines(StringBuffer str_buffer, String s_quoteStart, String s_quoteEnd, String s_lineSep)
          Get a copy of the StringBuffer (as a StringBuffer) where each line is quoted.
 StringBuffer getReplaceAll(StringBuffer str_buffer, String s_replaceWhat, String s_replaceWith)
          Return a copy of the provided StringBuffer, in which all occurances are replaced.
 StringBuffer getReplaceUntil(StringBuffer str_buffer, String s_replaceWhat, String s_replaceWith)
          Replace all occurances, with multiple passes, until no instances of the search string remain.
 SOBString getSOBS(StringBuffer str_buffer, String s_callingClsFnc)
          Create an SOBString from the StringBuffer.
 SOBString getSOBS(StringBuffer str_buffer, String s_sbDesc, String s_callingClsFnc)
          Create an SOBString from the StringBuffer.
 SOBStringBuffer getSOBSB(StringBuffer str_buffer, String s_callingClsFnc)
          Create an SOBStringBuffer from the StringBuffer.
 SOBStringBuffer getSOBSB(StringBuffer str_buffer, String s_sbDesc, String s_callingClsFnc)
          Create an SOBStringBuffer from the StringBuffer.
 StringBuffer getVisible(StringBuffer str_buffer)
          Get a copy of the StringBuffer, where the contents' invisible characters are made visible.
 boolean hasDigitsOrInAOC(StringBuffer str_buffer, boolean b_lettersOkOpt, char[] ac_legal)
          Does the string contain only digits and (other provided) legal characters?
 boolean hasDigitsOrInAOC(StringBuffer str_buffer, boolean b_lettersOkOpt, char[] ac_legal, boolean b_validateAOC)
          Does the string contain only digits and (other provided) legal characters?
 boolean hasLDOrInAOC(StringBuffer str_buffer, char[] ac_legal)
          Does the string contain only letters, digits and (other provided) legal characters?
 boolean hasLDOrInAOC(StringBuffer str_buffer, char[] ac_legal, boolean b_validateAOC)
          Does the string contain only letters, digits and (other provided) legal characters?
 boolean hasLegalChars(StringBuffer str_buffer, char[] ac_legal)
          Does the string contain only legal characters?
 boolean hasLegalChars(StringBuffer str_buffer, char[] ac_legal, boolean b_validateAOC)
          Does the string contain only legal characters?
 boolean hasLettersOrInAOC(StringBuffer str_buffer, boolean b_digitsOkOpt, char[] ac_legal)
          Does the string contain only letters and (other provided) legal characters?
 boolean hasLettersOrInAOC(StringBuffer str_buffer, boolean b_digitsOkOpt, char[] ac_legal, boolean b_validateAOC)
          Does the string contain only letters and (other provided) legal characters?
 boolean hasNoIllegalChars(StringBuffer str_buffer, char[] ac_illegal)
          Does the string not contain any illegal characters?
 boolean hasNoIllegalChars(StringBuffer str_buffer, char[] ac_illegal, boolean b_validateAOC)
          Does the string not contain any illegal characters?
 boolean hasNoTabSpace(StringBuffer str_buffer)
          Does the StringBuffer not contain any tabs and space characters?
 boolean isHexidecimal(StringBuffer sb_potentialHex)
          Is the value of the StringBuffer a valid hexidecimal number?
 boolean isLegal(StringBuffer str_buffer, boolean b_lettersOkOpt, boolean b_digitsOkOpt, char[] ac_legal)
          Does the string contain only legal characters?
 boolean isLegal(StringBuffer str_buffer, boolean b_lettersOkOpt, boolean b_digitsOkOpt, char[] ac_legal, boolean b_validateAOC)
          Does the string contain only legal characters?
 boolean isLetterDigitUnderscore(StringBuffer str_buffer)
          Does the string contain only letters, digits and underscores?
 boolean isNotDigitsOrInAOC(StringBuffer str_buffer, boolean b_lettersBadOpt, char[] ac_legal)
          Does the string not contain any digits or (other provided) illegal characters?
 boolean isNotDigitsOrInAOC(StringBuffer str_buffer, boolean b_lettersBadOpt, char[] ac_legal, boolean b_validateAOC)
          Does the string not contain any digits or (other provided) illegal characters?
 boolean isNotIllegal(StringBuffer str_buffer, boolean b_lettersBadOpt, boolean b_digitsBadOpt, char[] ac_illegal)
          Does the string not contain any illegal characters?
 boolean isNotIllegal(StringBuffer str_buffer, boolean b_lettersBadOpt, boolean b_digitsBadOpt, char[] ac_illegal, boolean b_validateAOC)
          Does the string not contain any illegal characters?
 boolean isNotLDOrInAOC(StringBuffer str_buffer, char[] ac_legal)
          Does the string not contain any letters, digits or (other provided) illegal characters?
 boolean isNotLDOrInAOC(StringBuffer str_buffer, char[] ac_legal, boolean b_validateAOC)
          Does the string not contain any letters, digits or (other provided) illegal characters?
 boolean isNotLettersOrInAOC(StringBuffer str_buffer, boolean b_digitsBadOpt, char[] ac_legal)
          Does the string not contain any letters or (other provided) illegal characters?
 boolean isNotLettersOrInAOC(StringBuffer str_buffer, boolean b_digitsBadOpt, char[] ac_legal, boolean b_validateAOC)
          Does the string not contain any letters or (other provided) illegal characters?
 boolean isTabSpace(StringBuffer sb_potentialTabSpace)
          Does the StringBuffer contain only tabs and spaces?
 void makeVisible(StringBuffer str_buffer)
          Translate the contents of a StringBuffer, so all invisible characters are made visible.
 void quoteLines(StringBuffer str_buffer)
          Quote each line within a StringBuffer.
 void quoteLines(StringBuffer str_buffer, String s_quote)
          Quote each line within a StringBuffer.
 void quoteLines(StringBuffer str_buffer, String s_quoteStart, String s_quoteEnd)
          Quote each line within a StringBuffer.
 void quoteLines(StringBuffer str_buffer, String s_quoteStart, String s_quoteEnd, String s_lineSep)
          Quote each line within a StringBuffer.
 int replaceAll(StringBuffer str_buffer, String s_replaceWhat, String s_replaceWith)
          Replace all occurances.
 i_i replaceUntil(StringBuffer str_buffer, String s_replaceWhat, String s_replaceWith)
          Replace all occurances, with multiple passes, until no instances of the search string remain.
 
Methods inherited from class xbn.string.UtilSOB
dupAppend, getContainedIdxs, getContainedIdxs, getContainedIdxs, getContainedIdxs, getDupAppend, getGSAInfo, getIdxOf1stCharNIA, getIdxOf1stCharNIA, getIdxOf1stCharNIA, getIdxOf1stCharNIA, getIdxOf1stNonWS, getIdxOfLastCharNIA, getIdxOfLastCharNIA, getIdxOfLastCharNIA, getIdxOfLastCharNIA, getIdxOfLastNonWS, getQuotedLines, getQuotedLines, getQuotedLines, getQuotedLines, getReplaceAll, getReplaceUntil, getSOBS, getSOBS, getSOBSB, getSOBSB, getStringAround, getVisible, hasDigitsOrInAOC, hasDigitsOrInAOC, hasLDOrInAOC, hasLDOrInAOC, hasLegalChars, hasLegalChars, hasLettersOrInAOC, hasLettersOrInAOC, hasNoIllegalChars, hasNoIllegalChars, hasNoTabSpace, indexOfWord, indexOfWord, isHexidecimal, isLegal, isLegal, isLetterDigitUnderscore, isNotDigitsOrInAOC, isNotDigitsOrInAOC, isNotIllegal, isNotIllegal, isNotLDOrInAOC, isNotLDOrInAOC, isNotLettersOrInAOC, isNotLettersOrInAOC, isTabSpace, lastIndexOfWord, lastIndexOfWord, makeVisible, quoteLines, quoteLines, quoteLines, quoteLines, replaceAll, replaceUntil, throwAXIfBadSOB
 
Methods inherited from class xbn.XBNObject
getXMsgPrefix, sop, sopl, sopl, throwAX, throwAXIfBadStr, throwAXIfNull, throwAXSpoof
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sUSB

public static final String sUSB

To shorten code and Javadoc.

Equal to "xbn.string.UtilStringBuffer."

Constructor Detail

UtilStringBuffer

public UtilStringBuffer()

Create a UtilStringBuffer. This constructor does nothing.

Method Detail

getQuotedLines

public final StringBuffer getQuotedLines(StringBuffer str_buffer)

Get a copy of the StringBuffer where each line is quoted.

Returns:
((SOBStringBuffer)getQuotedLines(getSOBSB(str_buffer, sUSB + "getQuotedLines"))).getStringBuffer()

getQuotedLines

public final StringBuffer getQuotedLines(StringBuffer str_buffer,
                                         String s_quote)

Get a copy of the StringBuffer where each line is quoted.

Returns:
((SOBStringBuffer)getQuotedLines(getSOBSB(str_buffer, sUSB + "getQuotedLines"), s_quote)).getStringBuffer()

getQuotedLines

public final StringBuffer getQuotedLines(StringBuffer str_buffer,
                                         String s_quoteStart,
                                         String s_quoteEnd)

Get a copy of the StringBuffer where each line is quoted.

Returns:
((SOBStringBuffer)getQuotedLines(getSOBSB(str_buffer, sUSB + "getQuotedLines"), s_quoteStart, s_quoteEnd)).getStringBuffer()

getQuotedLines

public final StringBuffer getQuotedLines(StringBuffer str_buffer,
                                         String s_quoteStart,
                                         String s_quoteEnd,
                                         String s_lineSep)

Get a copy of the StringBuffer (as a StringBuffer) where each line is quoted.

Returns:
((SOBStringBuffer)getQuotedLines(getSOBSB(str_buffer, sUSB + "getQuotedLines"), s_quoteStart, s_quoteEnd, s_lineSep)).getStringBuffer()

quoteLines

public final void quoteLines(StringBuffer str_buffer)

Quote each line within a StringBuffer.

Equal to quoteLines(str_buffer, sUSB + "'")


quoteLines

public final void quoteLines(StringBuffer str_buffer,
                             String s_quote)

Quote each line within a StringBuffer.

Equal to quoteLines(getSOBSB(str_buffer, sUSB + "quoteLines"), s_quote)


quoteLines

public final void quoteLines(StringBuffer str_buffer,
                             String s_quoteStart,
                             String s_quoteEnd)

Quote each line within a StringBuffer.

Equal to quoteLines(str_buffer, s_quoteStart, s_quoteEnd)


quoteLines

public final void quoteLines(StringBuffer str_buffer,
                             String s_quoteStart,
                             String s_quoteEnd,
                             String s_lineSep)

Quote each line within a StringBuffer.


getReplaceAll

public final StringBuffer getReplaceAll(StringBuffer str_buffer,
                                        String s_replaceWhat,
                                        String s_replaceWith)

Return a copy of the provided StringBuffer, in which all occurances are replaced.

Returns:
getReplaceAll(getSOBSB(str_buffer, sUSB + "getReplaceAll"), s_replaceWhat, s_replaceWith).getStringBuffer()

replaceAll

public final int replaceAll(StringBuffer str_buffer,
                            String s_replaceWhat,
                            String s_replaceWith)

Replace all occurances.

Returns:
replaceAll(getSOBSB(str_buffer, sUSB + "replaceAll"), s_replaceWhat, s_replaceWith)

getReplaceUntil

public final StringBuffer getReplaceUntil(StringBuffer str_buffer,
                                          String s_replaceWhat,
                                          String s_replaceWith)

Replace all occurances, with multiple passes, until no instances of the search string remain.

Returns:
getReplaceUntil(getSOBSB(str_buffer, sUSB + "getReplaceUntil"), s_replaceWhat, s_replaceWith)

replaceUntil

public final i_i replaceUntil(StringBuffer str_buffer,
                              String s_replaceWhat,
                              String s_replaceWith)

Replace all occurances, with multiple passes, until no instances of the search string remain.

Returns:
replaceUntil(getSOBSB(str_buffer, sUSB + "replaceUntil"), s_replaceWhat, s_replaceWith)

isHexidecimal

public boolean isHexidecimal(StringBuffer sb_potentialHex)

Is the value of the StringBuffer a valid hexidecimal number?

Returns:
isHexidecimal(getSOBSB(sb_potentialHex, "sb_potentialHex", "isHexidecimal"))

isTabSpace

public boolean isTabSpace(StringBuffer sb_potentialTabSpace)

Does the StringBuffer contain only tabs and spaces?

Parameters:
sb_potentialTabSpace - The StringBuffer analyzed, to see if it contains only tabs and spaces characters. May not be null or zero characters in length.
Returns:
isTabSpace(getSOBSB(sb_potentialTabSpace, "sb_potentialTabSpace", "isTabSpace"))

hasNoTabSpace

public boolean hasNoTabSpace(StringBuffer str_buffer)

Does the StringBuffer not contain any tabs and space characters?

Parameters:
str_buffer - The StringBuffer analyzed, to see if it contains only non-tabs and non-space characters. May not be null or zero characters in length.
Returns:
hasNoTabSpace(getSOBSB(str_buffer, sUSB + "hasNoTabSpace"))

dupAppend

public final void dupAppend(StringBuffer str_buffer,
                            String s_toDuplicate,
                            int i_dupCount)

Append a duplicated string onto the StringBuffer.

Equal to dupAppend(getSOBSB(str_buffer, sUSB + "dupAppend"), s_toDuplicate, i_dupCount)


getDupAppend

public final StringBuffer getDupAppend(StringBuffer str_buffer,
                                       String s_toDuplicate,
                                       int i_dupCount)

Get a copy of the StringBuffer, after appending a duplicated string onto it.

Returns:
((SOBStringBuffer)dupAppend(getSOBSB(str_buffer, sUSB + "getDupAppend"), s_toDuplicate, i_dupCount)).getStringBuffer()

getIdxOf1stNonWS

public final int getIdxOf1stNonWS(StringBuffer str_buffer)

Get the array index of the first non-white-space character.

Returns:
getIdxOf1stNonWS(getSOBSB(str_buffer, sUSB + "getIdxOf1stNonWS"))

getIdxOfLastNonWS

public final int getIdxOfLastNonWS(StringBuffer str_buffer)

Get the array index of the last non-white-space character.

Returns:
getIdxOfLastNonWS(getSOBSB(str_buffer, sUSB + "getIdxOfLastNonWS"))

getIdxOf1stCharNIA

public final int getIdxOf1stCharNIA(StringBuffer str_buffer,
                                    char[] a_char)

Get the array index of the first character that is not a member of the array.

Returns:
getIdxOf1stCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOf1stCharNIA"), a_char)

getIdxOf1stCharNIA

public final int getIdxOf1stCharNIA(StringBuffer str_buffer,
                                    char[] a_char,
                                    boolean b_validateAOC)

Get the array index of the first character that is not a member of the array.

Returns:
getIdxOf1stCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOf1stCharNIA"), a_char, 0, str_buffer.length(), b_validateAOC)

getIdxOf1stCharNIA

public final int getIdxOf1stCharNIA(StringBuffer str_buffer,
                                    char[] a_char,
                                    int i_idxStart,
                                    int i_idxAfterEnd)

Get the array index of the first character that is not a member of the array.

Returns:
getIdxOf1stCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOf1stCharNIA"), a_char, i_idxStart, i_idxAfterEnd)

getIdxOf1stCharNIA

public final int getIdxOf1stCharNIA(StringBuffer str_buffer,
                                    char[] a_char,
                                    int i_idxStart,
                                    int i_idxAfterEnd,
                                    boolean b_validateAOC)

Get the array index of the first character that does not exist in the array.

Returns:
getIdxOf1stCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOf1stCharNIA"), a_char, i_idxStart, i_idxAfterEnd, b_validateAOC)

getIdxOfLastCharNIA

public final int getIdxOfLastCharNIA(StringBuffer str_buffer,
                                     char[] a_char)

Get the array index of the last character that is not a member of the array.

Returns:
getIdxOfLastCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOfLastCharNIA"), a_char)

getIdxOfLastCharNIA

public final int getIdxOfLastCharNIA(StringBuffer str_buffer,
                                     char[] a_char,
                                     boolean b_validateAOC)

Get the array index of the last character that is not a member of the array.

Returns:
getIdxOfLastCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOfLastCharNIA"), a_char, 0, length(), b_validateAOC)

getIdxOfLastCharNIA

public final int getIdxOfLastCharNIA(StringBuffer str_buffer,
                                     char[] a_char,
                                     int i_idxStart,
                                     int i_idxAfterEnd)

Get the array index of the last character that is not a member of the array.

Returns:
getIdxOfLastCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOfLastCharNIA"), a_char, i_idxStart, i_idxAfterEnd)

getIdxOfLastCharNIA

public final int getIdxOfLastCharNIA(StringBuffer str_buffer,
                                     char[] a_char,
                                     int i_idxStart,
                                     int i_idxAfterEnd,
                                     boolean b_validateAOC)

Get the array index of the last character that does not exist in the array.

Returns:
getIdxOfLastCharNIA(getSOBSB(str_buffer, sUSB + "getIdxOfLastCharNIA"), a_char, i_idxStart, i_idxAfterEnd, b_validateAOC)

getVisible

public final StringBuffer getVisible(StringBuffer str_buffer)

Get a copy of the StringBuffer, where the contents' invisible characters are made visible.

Returns:
((SOBStringBuffer)getVisible(getSOBSB(str_buffer, sUSB + "getVisible")).getStringBuffer()

makeVisible

public final void makeVisible(StringBuffer str_buffer)

Translate the contents of a StringBuffer, so all invisible characters are made visible.

Equal to makeVisible(getSOBSB(str_buffer, sUSB + "getVisible"))


isLetterDigitUnderscore

public boolean isLetterDigitUnderscore(StringBuffer str_buffer)

Does the string contain only letters, digits and underscores?

Returns:
isLetterDigitUnderscore(getSOBSB(str_buffer, sUSB + "isLetterDigitUnderscore"))

hasLettersOrInAOC

public boolean hasLettersOrInAOC(StringBuffer str_buffer,
                                 boolean b_digitsOkOpt,
                                 char[] ac_legal)

Does the string contain only letters and (other provided) legal characters?

Returns:
hasLettersOrInAOC(getSOBSB(str_buffer, sUSB + "hasLettersOrInAOC"), b_digitsOkOpt, ac_legal)

hasLettersOrInAOC

public boolean hasLettersOrInAOC(StringBuffer str_buffer,
                                 boolean b_digitsOkOpt,
                                 char[] ac_legal,
                                 boolean b_validateAOC)

Does the string contain only letters and (other provided) legal characters?

Returns:
hasLettersOrInAOC(getSOBSB(str_buffer, sUSB + "hasLettersOrInAOC"), b_digitsOkOpt, ac_legal, b_validateAOC)

hasDigitsOrInAOC

public boolean hasDigitsOrInAOC(StringBuffer str_buffer,
                                boolean b_lettersOkOpt,
                                char[] ac_legal)

Does the string contain only digits and (other provided) legal characters?

Returns:
hasDigitsOrInAOC(getSOBSB(str_buffer, sUSB + "hasDigitsOrInAOC"), b_lettersOkOpt, ac_legal)

hasDigitsOrInAOC

public boolean hasDigitsOrInAOC(StringBuffer str_buffer,
                                boolean b_lettersOkOpt,
                                char[] ac_legal,
                                boolean b_validateAOC)

Does the string contain only digits and (other provided) legal characters?

Returns:
hasDigitsOrInAOC(getSOBSB(str_buffer, sUSB + "hasDigitsOrInAOC"), b_lettersOkOpt, ac_legal, b_validateAOC)

hasLDOrInAOC

public boolean hasLDOrInAOC(StringBuffer str_buffer,
                            char[] ac_legal)

Does the string contain only letters, digits and (other provided) legal characters?

Returns:
hasLDOrInAOC(getSOBSB(str_buffer, sUSB + "hasLDOrInAOC"), ac_legal)

hasLDOrInAOC

public boolean hasLDOrInAOC(StringBuffer str_buffer,
                            char[] ac_legal,
                            boolean b_validateAOC)

Does the string contain only letters, digits and (other provided) legal characters?

Returns:
hasLDOrInAOC(getSOBSB(str_buffer, sUSB + "hasLDOrInAOC"), ac_legal, b_validateAOC)

hasLegalChars

public boolean hasLegalChars(StringBuffer str_buffer,
                             char[] ac_legal)

Does the string contain only legal characters?

Returns:
hasLegalChars(getSOBSB(str_buffer, sUSB + "hasLegalChars"), ac_legal)

hasLegalChars

public boolean hasLegalChars(StringBuffer str_buffer,
                             char[] ac_legal,
                             boolean b_validateAOC)

Does the string contain only legal characters?

Returns:
isLegal(getSOBSB(str_buffer, sUSB + "hasLegalChars"), false, false, ac_legal, b_validateAOC)

isLegal

public boolean isLegal(StringBuffer str_buffer,
                       boolean b_lettersOkOpt,
                       boolean b_digitsOkOpt,
                       char[] ac_legal)

Does the string contain only legal characters?

Returns:
isLegal(getSOBSB(str_buffer, sUSB + "isLegal"), b_lettersOkOpt, b_digitsOkOpt, ac_legal)

isLegal

public boolean isLegal(StringBuffer str_buffer,
                       boolean b_lettersOkOpt,
                       boolean b_digitsOkOpt,
                       char[] ac_legal,
                       boolean b_validateAOC)

Does the string contain only legal characters?

Returns:
isLegal(getSOBSB(str_buffer, sUSB + "isLegal"), b_lettersOkOpt, b_digitsOkOpt, ac_legal, b_validateAOC)

isNotLettersOrInAOC

public boolean isNotLettersOrInAOC(StringBuffer str_buffer,
                                   boolean b_digitsBadOpt,
                                   char[] ac_legal)

Does the string not contain any letters or (other provided) illegal characters?

Returns:
isNotLettersOrInAOC(getSOBSB(str_buffer, sUSB + "isNotLettersOrInAOC"), b_digitsBadOpt, ac_legal)

isNotLettersOrInAOC

public boolean isNotLettersOrInAOC(StringBuffer str_buffer,
                                   boolean b_digitsBadOpt,
                                   char[] ac_legal,
                                   boolean b_validateAOC)

Does the string not contain any letters or (other provided) illegal characters?

Returns:
isNotLettersOrInAOC(getSOBSB(str_buffer, sUSB + "isNotLettersOrInAOC"), b_digitsBadOpt, ac_legal, b_validateAOC)

isNotDigitsOrInAOC

public boolean isNotDigitsOrInAOC(StringBuffer str_buffer,
                                  boolean b_lettersBadOpt,
                                  char[] ac_legal)

Does the string not contain any digits or (other provided) illegal characters?

Returns:
isNotDigitsOrInAOC(getSOBSB(str_buffer, sUSB + "isNotDigitsOrInAOC"), b_digitsBadOpt, ac_legal)

isNotDigitsOrInAOC

public boolean isNotDigitsOrInAOC(StringBuffer str_buffer,
                                  boolean b_lettersBadOpt,
                                  char[] ac_legal,
                                  boolean b_validateAOC)

Does the string not contain any digits or (other provided) illegal characters?

Returns:
isNotDigitsOrInAOC(getSOBSB(str_buffer, sUSB + "isNotDigitsOrInAOC"), b_lettersBadOpt, ac_legal, b_validateAOC)

isNotLDOrInAOC

public boolean isNotLDOrInAOC(StringBuffer str_buffer,
                              char[] ac_legal)

Does the string not contain any letters, digits or (other provided) illegal characters?

Returns:
isNotLDOrInAOC(getSOBSB(str_buffer, sUSB + "isNotLDOrInAOC"), ac_legal)

isNotLDOrInAOC

public boolean isNotLDOrInAOC(StringBuffer str_buffer,
                              char[] ac_legal,
                              boolean b_validateAOC)

Does the string not contain any letters, digits or (other provided) illegal characters?

Returns:
isNotLDOrInAOC(getSOBSB(str_buffer, sUSB + "isNotLDOrInAOC"), ac_legal, b_validateAOC)

hasNoIllegalChars

public boolean hasNoIllegalChars(StringBuffer str_buffer,
                                 char[] ac_illegal)

Does the string not contain any illegal characters?

Returns:
hasNoIllegalChars(getSOBSB(str_buffer, sUSB + "hasNoIllegalChars"), ac_illegal)

hasNoIllegalChars

public boolean hasNoIllegalChars(StringBuffer str_buffer,
                                 char[] ac_illegal,
                                 boolean b_validateAOC)

Does the string not contain any illegal characters?

Returns:
isNotIllegal(getSOBSB(str_buffer, sUSB + "hasNoIllegalChars"), false, false, ac_illegal, b_validateAOC)

isNotIllegal

public boolean isNotIllegal(StringBuffer str_buffer,
                            boolean b_lettersBadOpt,
                            boolean b_digitsBadOpt,
                            char[] ac_illegal)

Does the string not contain any illegal characters?

Returns:
isNotIllegal(getSOBSB(str_buffer, sUSB + "isNotIllegal"), b_lettersBadOpt, b_digitsBadOpt, ac_illegal)

isNotIllegal

public boolean isNotIllegal(StringBuffer str_buffer,
                            boolean b_lettersBadOpt,
                            boolean b_digitsBadOpt,
                            char[] ac_illegal,
                            boolean b_validateAOC)

Does the string not contain any illegal characters?

Returns:
isNotIllegal(getSOBSB(str_buffer, sUSB + "isNotLegal"), b_lettersBadOpt, b_digitsBadOpt, ac_illegal, b_validateAOC)

getSOBS

public final SOBString getSOBS(StringBuffer str_buffer,
                               String s_callingClsFnc)

Create an SOBString from the StringBuffer.

Returns:
getSOBS(str_buffer, sUSB + "str_buffer", s_callingClsFnc)

getSOBS

public final SOBString getSOBS(StringBuffer str_buffer,
                               String s_sbDesc,
                               String s_callingClsFnc)

Create an SOBString from the StringBuffer.

Parameters:
str_buffer - The StringBuffer to create a new SOBString with. May not be null.
s_sDescription - The descriptive name of str_buffer, for potential error messages.
s_callingClsFnc - The function from which the potential error message should appear as if it is coming from.
Returns:
(new SOBString(str_buffer.toString()))

getSOBSB

public final SOBStringBuffer getSOBSB(StringBuffer str_buffer,
                                      String s_callingClsFnc)

Create an SOBStringBuffer from the StringBuffer.

Returns:
getSOBSB(str_buffer, sUSB + "str_buffer", s_callingClsFnc)

getSOBSB

public final SOBStringBuffer getSOBSB(StringBuffer str_buffer,
                                      String s_sbDesc,
                                      String s_callingClsFnc)

Create an SOBStringBuffer from the StringBuffer.

Parameters:
str_buffer - The StringBuffer to create a new SOBStringBuffer with. May not be null.
s_sDescription - The descriptive name of str_buffer, for potential error messages.
s_callingClsFnc - The function from which the potential error message should appear as if it is coming from.
Returns:
(new SOBStringBuffer(str_buffer))

getAOSOBS

public final SOBString[] getAOSOBS(StringBuffer[] a_stringBuffer)

Get an array of SOBStrings from the array of StringBuffers.

Parameters:
a_stringBuffer - The array of strings to create an array of SOBStrings from.
Returns:
null If a_stringBuffer is null.
An array of SOBStrings where each element has contents equalling that in the corresponding member of a_stringBuffer. Note: If a_stringBuffer[X] is null then the X-th element in the returned array is also null (it is not possible to have the contents of an SOBString equal null).

getAOSOBSB

public final SOBStringBuffer[] getAOSOBSB(StringBuffer[] a_stringBuffer)

Get an array of SOBStringBuffers from the array of StringBuffers.

Parameters:
a_stringBuffer - The array of strings to create an array of SOBStringBuffers from.
Returns:
null If a_stringBuffer is null.
An array of SOBStringBuffers where each element has contents equalling that in the corresponding member of a_stringBuffer. Note: If a_stringBuffer[X] is null then the X-th element in the returned array is also null (it is not possible to have the contents of an SOBStringBuffer equal null).



Copyright 1997-2003, Jeff Epstein, All Rights Reserved. See top of source code files for copyright notice.

 

http://sourceforge.net/projects/xbnjava

 

SourceForge.net Logo