# HG changeset patch # User Frank Benoit # Date 1207948751 -7200 # Node ID 4e6393f432311bf421ef44d0839753892192f581 # Parent 6da025bf255e6c20700c4edc71808daa5771a58e Boolean valueOf diff -r 6da025bf255e -r 4e6393f43231 dwt/dwthelper/utils.d --- a/dwt/dwthelper/utils.d Fri Apr 11 17:50:39 2008 +0200 +++ b/dwt/dwthelper/utils.d Fri Apr 11 23:19:11 2008 +0200 @@ -94,6 +94,15 @@ public bool booleanValue(){ return value; } + public static Boolean valueOf( char[] s ){ + if( s == "yes" || s == "true" ){ + return TRUE; + } + return FALSE; + } + public static Boolean valueOf( bool b ){ + return b ? TRUE : FALSE; + } } alias Boolean ValueWrapperBool;