BloombergLP::bdlt::Datetime::Datetime

Constructors

Synopses

Declared in <bdlt_datetime.h>

Create a Datetime object whose "date" and "time" parts have their respective default-constructed values, "0001/01/01" and "24:00:00.000000".

Datetime();
» more...

Create a Datetime object having the value of the specified original object.

Datetime(Datetime const& original);
» more...

Create a Datetime object whose "date" part has the value of the specified date and whose "time" part has the value "00:00:00.000000".

Datetime(Date const& date);
» more...

Create a Datetime object whose "date" and "time" parts have the values of the specified date and time, respectively.

Datetime(
    Date const& date,
    Time const& time);
» more...

Create a Datetime from year, month, day, and optional time fields.

Datetime(
    int year,
    int month,
    int day,
    int hour = 0,
    int minute = 0,
    int second = 0,
    int millisecond = 0,
    int microsecond = 0);
» more...

Parameters

NameDescription
originaldatetime whose value is copied
datedate part of the new value
timetime part of the new value
yearyear attribute
monthmonth attribute
dayday-of-month attribute
hourhour attribute (default 0)
minuteminute attribute (default 0)
secondsecond attribute (default 0)
millisecondmillisecond attribute (default 0)
microsecondmicrosecond attribute (default 0)