Packageorg.pranaframework.utils
Classpublic class StringUtils

Contains utility methods for working with strings.



Public Methods
 MethodDefined by
  
addAt(string:String, value:int, position:*):String
[static] Adds/inserts a new string at a certain position in the source string.
StringUtils
  
fixNewlines(string:String):String
[static] Fixes double newlines in a text.
StringUtils
  
hasText(string:String):Boolean
[static] Checks if the given string has actual text.
StringUtils
  
removeAt(string:String, beginIndex:int, endIndex:int):String
[static] Removes a part of the text between 2 positions.
StringUtils
  
replaceAt(string:String, value:int, beginIndex:int, endIndex:*):String
[static] Replaces a part of the text between 2 positions.
StringUtils
Method detail
addAt()method
public static function addAt(string:String, value:int, position:*):String

Adds/inserts a new string at a certain position in the source string.

Parameters
string:String
 
value:int
 
position:*

Returns
String
fixNewlines()method 
public static function fixNewlines(string:String):String

Fixes double newlines in a text.

Parameters
string:String

Returns
String
hasText()method 
public static function hasText(string:String):Boolean

Checks if the given string has actual text.

Parameters
string:String

Returns
Boolean
removeAt()method 
public static function removeAt(string:String, beginIndex:int, endIndex:int):String

Removes a part of the text between 2 positions.

Parameters
string:String
 
beginIndex:int
 
endIndex:int

Returns
String
replaceAt()method 
public static function replaceAt(string:String, value:int, beginIndex:int, endIndex:*):String

Replaces a part of the text between 2 positions.

Parameters
string:String
 
value:int
 
beginIndex:int
 
endIndex:*

Returns
String