Microsoft.CSharp.RuntimeBinder.Semantics.ConstValFactory.GetBool C# (CSharp) Method

GetBool() public static method

public static GetBool ( bool value ) : CONSTVAL
value bool
return CONSTVAL
        public static CONSTVAL GetBool(bool value)
        {
            CONSTVAL result = new CONSTVAL();
            result.boolVal = value;
            return result;
        }

Usage Example

 public EXPRCONSTANT CreateBoolConstant(bool b)
 {
     return(CreateConstant(GetTypes().GetReqPredefAgg(PredefinedType.PT_BOOL).getThisType(), ConstValFactory.GetBool(b)));
 }