Packageorg.springextensions.actionscript.utils
SVN browsingMultilineString.as
FisheyeMultilineString.as
Classpublic class MultilineString

MultilineString allows to access all lines of a string separately.

To not have to deal with different forms of line breaks (Windows/Apple/Unix) MultilineString automatically standardizes them to the \n character. So the passed-in String will always get standardized.

If you need to access the original String you can use getOriginalString.



Public Properties
 PropertyDefined by
  lines : Array
[read-only] Returns the content as array that contains each line.
MultilineString
  numLines : uint
[read-only] Returns the amount of lines in the content.
MultilineString
  originalString : String
[read-only] Returns the original used string (without line break standarisation).
MultilineString
Public Methods
 MethodDefined by
  
MultilineString(string:String)
Constructs a new MultilineString.
MultilineString
  
getLine(line:uint):String
Returns a specific line within the MultilineString.
MultilineString
Property detail
linesproperty
lines:Array  [read-only]

Returns the content as array that contains each line.

Implementation
    public function get lines():Array
numLinesproperty 
numLines:uint  [read-only]

Returns the amount of lines in the content.

Implementation
    public function get numLines():uint
originalStringproperty 
originalString:String  [read-only]

Returns the original used string (without line break standarisation).

Implementation
    public function get originalString():String
Constructor detail
MultilineString()constructor
public function MultilineString(string:String)

Constructs a new MultilineString.

Parameters
string:String
Method detail
getLine()method
public function getLine(line:uint):String

Returns a specific line within the MultilineString.

It will return undefined if the line does not exist.

The line does not contain the line break.

The counting of lines startes with 0.

Parameters
line:uint — number of the line to get the content of

Returns
String — content of the line