[#BloombergLP-bdlt-DateFormatter_Cache]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlt.adoc[bdlt]::DateFormatter&lowbar;Cache
:relfileprefix: ../../
:mrdocs:

Cached `Date` fields for faster formatting&period;

== Synopsis

Declared in `&lt;bdlt&lowbar;dateformatter&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
class DateFormatter&lowbar;Cache;
----

== Description

This `class` facilitates faster access to a `Date` object during printing by batching access to several fields in a single call during construction and caching them for quick access later&period;

== Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bdlt/DateFormatter_Cache/2constructor.adoc[`DateFormatter&lowbar;Cache`]         [.small]#[constructor]#
| Cache a copy of the specified `value` and its `year`, `month`, and `day` fields&period;
| xref:BloombergLP/bdlt/DateFormatter_Cache/day.adoc[`day`] 
| Return the cached `day` field&period;
| xref:BloombergLP/bdlt/DateFormatter_Cache/dayOfWeek.adoc[`dayOfWeek`] 
| Call the `dayOfWeek` accessor of the cached date and return the value&period;
| xref:BloombergLP/bdlt/DateFormatter_Cache/dayOfYear.adoc[`dayOfYear`] 
| Call the `dayOfYear` accessor of the cached date and return the value&period;
| xref:BloombergLP/bdlt/DateFormatter_Cache/month.adoc[`month`] 
| Return the cached `month` field&period;
| xref:BloombergLP/bdlt/DateFormatter_Cache/year.adoc[`year`] 
| Return the cached year field&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
