BloombergLP::bdlt::Datetime::setYearDay

Set the date part from year and dayOfYear.

Synopsis

Declared in <bdlt_datetime.h>

void
setYearDay(
    int year,
    int dayOfYear);

Description

Set the "date" part of this object to have the value represented by the specified year and dayOfYear attribute values. The behavior is undefined unless year and dayOfYear represent a valid Date value (i.e., true == Date::isValidYearDay(year, dayOfYear)). Note that this method has no effect on the "time" part of this object.

Parameters

NameDescription
yearyear attribute
dayOfYearday-of-year attribute