[#BloombergLP-bdlt-PackedCalendar-holidayCode] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlt.adoc[bdlt]::xref:BloombergLP/bdlt/PackedCalendar.adoc[PackedCalendar]::holidayCode :relfileprefix: ../../../ :mrdocs: Return, for the holiday at the specified `date` in this calendar, the holiday code at the specified `index`. For all `index` values from 0 to `numHolidayCodes(date) ‐ 1` (inclusive), a unique holiday code is returned. The mapping of `index` to holiday code is invalidated when the set of holidays or holiday codes is modified by an invocation of `addHoliday`, `addHolidayCode`, `addHolidayCodeIfInRange`, `addHolidayIfInRange`, `intersectBusinessDays`, `intersectNonBusinessDays`, `removeAll`, `removeHoliday`, `removeHolidayCode`, `setValidRange`, `unionBusinessDays`, or `unionNonBusinessDays`. The behavior is undefined unless `date` is a holiday in this calendar and `0 <= index < numHolidayCodes(date)`. Note that this method facilitates testing and generally should not be used by clients; in particular, using this method to iterate over the holiday codes for `date` is less efficient than using a `HolidayCodeConstIterator`. == Synopsis Declared in `<bdlt_packedcalendar.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int holidayCode( xref:BloombergLP/bdlt/Date.adoc[Date] const& date, int index) const; ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#