com.konakart.al
Class TrimString

java.lang.Object
  extended by com.konakart.al.TrimString

public class TrimString
extends java.lang.Object

Utility class to trim strings so that they may be presented on the UI.


Field Summary
static java.lang.String END_TRIM
          Characters at the end of the trim
 
Constructor Summary
TrimString()
           
 
Method Summary
static java.lang.String trimEnd(java.lang.String in)
          Returns the string trimmed to the default length
static java.lang.String trimEnd(java.lang.String in, int length)
          Returns the string trimmed at the end to the length passed in as a parameter.
static java.lang.String trimMiddle(java.lang.String in)
          Returns the string trimmed in the middle to the default length.
static java.lang.String trimMiddle(java.lang.String in, int length)
          Returns the string trimmed in the middle to the length passed in as a parameter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

END_TRIM

public static java.lang.String END_TRIM
Characters at the end of the trim

Constructor Detail

TrimString

public TrimString()
Method Detail

trimEnd

public static java.lang.String trimEnd(java.lang.String in)
Returns the string trimmed to the default length

Parameters:
in -
Returns:
The string trimmed to the default length

trimEnd

public static java.lang.String trimEnd(java.lang.String in,
                                       int length)
Returns the string trimmed at the end to the length passed in as a parameter.

Parameters:
in -
length -
Returns:
The trimmed string

trimMiddle

public static java.lang.String trimMiddle(java.lang.String in)
Returns the string trimmed in the middle to the default length.

Parameters:
in -
Returns:
The parameter trimmed to the default length

trimMiddle

public static java.lang.String trimMiddle(java.lang.String in,
                                          int length)
Returns the string trimmed in the middle to the length passed in as a parameter.

Parameters:
in -
length -
Returns:
The trimmed string


Copyright © 2006 DS Data Systems UK Ltd.