public boolean getBoolean ( String key ) { LazyNode token = getFieldToken ( key ) ; if ( token . type == LazyNode . VALUE_STRING || token . type == LazyNode . VALUE_ESTRING ) { String str = token . getStringValue ( ) . toLowerCase ( ) . trim ( ) ; if ( str . equals ( "true" ) ) return true ; if ( str . equals ( "false" ) ) return false ; throw new LazyException ( "Requested value is not a boolean" , token ) ; } if ( token . type == LazyNode . VALUE_TRUE ) return true ; if ( token . type == LazyNode . VALUE_FALSE ) return false ; throw new LazyException ( "Requested value is not a boolean" , token ) ; }
Returns the boolean value stored in this object for the given key .