Private
Public Access
Finished BoolValue
This commit is contained in:
1 parent
767c35361d
commit
8ba36a4710
1 file changed
+13
-6
+13
-6
@@ -5,28 +5,35 @@ namespace Advanced_Software_Engineering.Verbs.Value.ValueTypes {
|
|||||||
|
|
||||||
internal class BoolValue : IValue {
|
internal class BoolValue : IValue {
|
||||||
|
|
||||||
|
bool value;
|
||||||
|
Type type = typeof(bool);
|
||||||
|
|
||||||
|
public BoolValue(bool value) {
|
||||||
|
this.value = value;
|
||||||
|
}
|
||||||
|
|
||||||
public string GetDescription() {
|
public string GetDescription() {
|
||||||
throw new NotImplementedException();
|
return "boolean of value " + value.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public Type GetOriginalType() {
|
public Type GetOriginalType() {
|
||||||
throw new NotImplementedException();
|
return type;
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool ToBool() {
|
public bool ToBool() {
|
||||||
throw new NotImplementedException();
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Color ToColor() {
|
public Color ToColor() {
|
||||||
throw new NotImplementedException();
|
return value ? Color.White : Color.Black;
|
||||||
}
|
}
|
||||||
|
|
||||||
public double ToDouble() {
|
public double ToDouble() {
|
||||||
throw new NotImplementedException();
|
return value ? 1d : 0d;
|
||||||
}
|
}
|
||||||
|
|
||||||
public int ToInt() {
|
public int ToInt() {
|
||||||
throw new NotImplementedException();
|
return value ? 1 : 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user