public abstract class Bool : DataTypeBase,
IComparable
Public MustInherit Class Bool
Inherits DataTypeBase
Implements IComparable
[<AbstractClassAttribute>]
type Bool =
class
inherit DataTypeBase
interface IComparable
end
using System;
using System.Collections.Generic;
using System.Text;
using NUnit.Framework;
using Firefly.Box;
using Firefly.Box.Testing;
namespace TestFirefly.Box.Documentation
{
[TestFixture]
public class DemoBool
{
[Test]
public void Test1()
{
Bool b = true;
b.ShouldBe(true);
b = false;
b.ShouldBe(false);
b = null;
if (b)
{
throw new Exception("When b is null, it should behave as false");
}
}
}
}
Bool | Initializes a new instance of the Bool class |
Cast | Casts the object specified in the value parameter to a Bool. If the cast fails an InvalidCastException is thrown |
CompareTo | Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. (Overrides DataTypeBaseCompareTo(Object)) |
Equals | Determines whether the specified Object is equal to the current Object. (Overrides ObjectEquals(Object)) |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) |
GetHashCode | Serves as the default hash function. (Inherited from Object) |
GetType | Gets the Type of the current instance. (Inherited from Object) |
IsSpecialNullInstance | |
IsTrue | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object) |
Not | |
ToBoolean | Converts to Boolean |
ToInt | Transforms the Bool to Int32 |
ToString | Returns a string that represents the current object. (Inherited from Object) |
ToString(String) | Returns a String that represents the current Bool. The result string is formatted using the format provided in the format parameter. (Overrides DataTypeBaseToString(String)) |
ToString(String, IFormatProvider) | Returns a String that represents the value specified in format. The result string is formatted using the format provided in the format parameter. (Inherited from DataTypeBase) |
TryCast | Tries to cast the object specified in the value parameter to a Boolean. |
ShouldBe | Verifies that the actual value matches the expected value (Defined by Should) |
ShouldBe | Verifies that the actual value matches the expected value (Defined by Should) |