com.ibm.commerce.marketingcenter.events.dbobjects
Class StringManipulationHelper

java.lang.Object
  |
  +--com.ibm.commerce.marketingcenter.events.dbobjects.StringManipulationHelper

public class StringManipulationHelper
extends java.lang.Object

This helper class provides various methods to manipulate strings.


Field Summary
static java.lang.String COPYRIGHT
          IBM copyright notice field.
 
Method Summary
static void main(java.lang.String[] args)
          Main method of this string helper utility.
static java.lang.String truncate(java.lang.String aString, char delimiter, int maxLength)
          This will truncate a string from the last occurrence of a particular delimiter to the maximum specified length.
static java.lang.String truncate(java.lang.String aString, int maxLength)
          This method takes a string and truncates it to a specific length.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail
public static final java.lang.String COPYRIGHT
IBM copyright notice field.
See Also:
Constant Field Values
Method Detail

main

public static void main(java.lang.String[] args)
Main method of this string helper utility.
Parameters:
args - optional arguments from the command line

truncate

public static java.lang.String truncate(java.lang.String aString,
                                        char delimiter,
                                        int maxLength)
This will truncate a string from the last occurrence of a particular delimiter to the maximum specified length.
Parameters:
aString - input string
delimiter - delimiter used in the string truncation
maxLength - the specific length of the output string
Returns:
output string

truncate

public static java.lang.String truncate(java.lang.String aString,
                                        int maxLength)
This method takes a string and truncates it to a specific length.
Parameters:
aString - input string
maxLength - the specific length of the output string
Returns:
output string