toDate - multiple declarations

Function toDate

Function to extract a Date from a text encoded column value.

Text representations of a Date are as in 2011-11-11

Prototype

std.datetime.Date toDate(
  string s
);

Parameters

NameDescription
s A string representation of the time difference.

Returns

A populated or default initialized std.datetime.Date struct.

Function toDate

Function to extract a Date from a binary encoded row.

Time/date structures are packed by the server into a byte sub-packet with a leading length byte, and a minimal number of bytes to embody the data.

Prototype

std.datetime.Date toDate(
  const(ubyte[]) a
) pure;

Parameters

NameDescription
a slice of a protocol packet beginning at the length byte for a chunk of Date data.

Returns

A populated or default initialized std.datetime.Date struct.

Authors

Copyright

License