Boolean.toString( ) Method

ActionScript for Flash MX: The Definitive Guide, 2nd Edition
By Colin Moock
Chapter 18.  ActionScript Language Reference
Boolean.toString( ) Method Flash 5

the value of the Boolean object converted to a string
booleanObject.toString()

Returns

The string "true" if the primitive value of booleanObject is true; "false" if the primitive value of booleanObject is false. The value of the Boolean object is specified when the object is constructed, and it is stored internally thereafter. Although the internal value of a Boolean object is obtainable via valueOf( ), we can use toString( ) to convert it to its string equivalent.

Description

The toString( ) method retrieves the primitive value of a Boolean object, converts that value to a string, and returns the resulting string.

Example

x = new Boolean(true); trace(x.toString());  // Displays: "true"

See Also

Object.toString( )



    ActionScript for Flash MX. The Definitive Guide
    ActionScript for Flash MX: The Definitive Guide, Second Edition
    ISBN: 059600396X
    EAN: 2147483647
    Year: 2002
    Pages: 780
    Authors: Colin Moock

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net