sealed class DT : MB <DateTime> { public override void To(IMapDataDestination d, object o, int i, DateTime v) { d.SetDateTime(o, i, v); }
public override void Map(IMapDataSource source, object sourceObject, int sourceIndex, IMapDataDestination destination, object destinationObject, int destinationIndex) { if(source.IsNull(sourceObject, sourceIndex)) { destination.SetDateTime(destinationObject, destinationIndex, DateTime.MinValue); } else { destination.SetDateTime(destinationObject, destinationIndex, Convert.ToDateTime(source.GetByte(sourceObject, sourceIndex))); } }