net.sf.ginp.util
Class StringTool

java.lang.Object
  extended by net.sf.ginp.util.StringTool

public class StringTool
extends java.lang.Object

Tools for common String manipulations.

Version:
$Revision: 287 $
Author:
$Author: dougculnane $

Constructor Summary
StringTool()
          Constructor for the StringTool object
 
Method Summary
static java.lang.String getXMLTagContent(java.lang.String tagName, java.lang.String xml)
          Gets the tagContent attribute of the StringTool class
static java.lang.String replace(java.lang.String txt, java.lang.String remove, java.lang.String replacement)
          Description of the Method
static java.lang.String[] splitToArray(java.lang.String txt, java.lang.String del)
          Split the string into an array based on the delininator.
static java.lang.String XMLEscape(java.lang.String input)
          This takes any string and escapes it so it doesn't interfere with any of the surrounding xml by inserting entities for the following -> amp, lt, gt, apos, quot
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringTool

public StringTool()
Constructor for the StringTool object

Method Detail

replace

public static java.lang.String replace(java.lang.String txt,
                                       java.lang.String remove,
                                       java.lang.String replacement)
Description of the Method

Parameters:
txt - Description of the Parameter
remove - Description of the Parameter
replacement - Description of the Parameter
Returns:
Description of the Return Value

splitToArray

public static java.lang.String[] splitToArray(java.lang.String txt,
                                              java.lang.String del)
Split the string into an array based on the delininator.

Parameters:
txt - Text to Split
del - Deliminator to Split on
Returns:
Array of Split values

getXMLTagContent

public static java.lang.String getXMLTagContent(java.lang.String tagName,
                                                java.lang.String xml)
Gets the tagContent attribute of the StringTool class

Parameters:
tagName - Description of the Parameter
xml - Description of the Parameter
Returns:
The tagContent value

XMLEscape

public static java.lang.String XMLEscape(java.lang.String input)
This takes any string and escapes it so it doesn't interfere with any of the surrounding xml by inserting entities for the following -> amp, lt, gt, apos, quot

Parameters:
input - the Inputed XML String
Returns:
the escaped XML String


Copyright © 2004-2007 null. All Rights Reserved.