Exemplo n.º 1
0
        private object GetValueExpectingType(DreamValueType type)
        {
            if (Type == type)
            {
                return(Value);
            }

            throw new Exception("Value " + this + " was not the expected type of " + type + "");
        }
Exemplo n.º 2
0
 public object GetValueExpectingType(DreamValueType type)
 {
     if (IsType(type))
     {
         return(Value);
     }
     else
     {
         throw new Exception("Value " + this + " was not the expected type of " + type + "");
     }
 }
Exemplo n.º 3
0
 public bool IsType(DreamValueType type)
 {
     return(((int)type & (int)Type) != 0);
 }