23 namespace Deveel.Data.Types {
35 : base(
"NULL", typeCode) {
43 var writer =
new BinaryWriter(stream);
46 writer.Write((byte)1);
47 }
else if (obj == null || obj.
IsNull) {
48 writer.Write((byte) 2);
50 throw new FormatException();
55 var reader =
new BinaryReader(stream);
56 var type = reader.ReadByte();
63 throw new NotImplementedException();
66 throw new FormatException();
70 if (obj == null || obj.
IsNull)
73 throw new InvalidCastException();
NullType(SqlTypeCode typeCode)
Constructs the type with the given SqlTypeCode.
NullType(ObjectData data)
bool IsNull
Gets a boolean value indicating if the object is NULL.
static readonly SqlNull Value
Defines the contract for a valid SQL Object
override ISqlObject DeserializeObject(Stream stream)
Defines the properties of a specific SQL Type and handles the values compatible.
SqlTypeCode
Enumerates the codes of all SQL types handled by the system.
override object ConvertTo(ISqlObject obj, Type destType)
A data type that represents the NULL value of a given SQL data type.
override void SerializeObject(Stream stream, ISqlObject obj)