public static boolean toBoolean ( final String value ) { String trimmedLowerValue = value . toLowerCase ( ) . trim ( ) ; return trimmedLowerValue . equals ( "1" ) || trimmedLowerValue . equals ( "true" ) || trimmedLowerValue . equals ( "yes" ) ; }
Converts a string to a boolean .