This topic covers the implementation details of TVarDates.
Scope: cpHolidaysList.pas; class derived from THolidaysList. Prepared from the curated implementation supplied for this review on 2 October 2026.
Uses the same indexed holiday-set list behavior as THolidaysList and adds property-level SkipFirstOccurrence and SkipLastOccurrence. These options are read after list processing.
Notation and shared helper rules: Reading this reference.
Literal rec_type values emitted within these routines: TCountryIdList. Nested values may belong to child wrappers rather than this owner itself; the attribute entries below give their exact locations.
Inherited implementation: THolidaysList. Follow it when the ordered behavior invokes inherited methods; inherited fields are not repeated as locally owned fields.
Exact XML fields and attributes
The paths below start at this record or property node. A slash identifies a child element; @ identifies an attribute. Curly braces mark a variable index or expression, not literal XML text. Initial values describe initialization; they do not establish what an omitted individual element does. The Implementation toggle below contains the supplied routines for exact branch order and conversions.
ListCountries/HolidaysSet[@id={i.toString}]
XML representation: The text of the HolidaysSet[@id={i.toString}] element.
Reading: Converts the stored text to a number and assigns it to aPropValue.ListCountries[i] when the record node exists; for each i from low (TCountryIdList) through high (TCountryIdList); node2 exists.
Export: No corresponding write is implemented locally. This can be a compatibility input or a field handled elsewhere.
SkipFirstOccurrence
XML representation: The text of the SkipFirstOccurrence element.
Reading: Reads the element into SkipFirstOccurrence.
Export: No corresponding write is implemented locally. This can be a compatibility input or a field handled elsewhere.
SkipLastOccurrence
XML representation: The text of the SkipLastOccurrence element.
Reading: Reads the element into SkipLastOccurrence.
Export: No corresponding write is implemented locally. This can be a compatibility input or a field handled elsewhere.
@prop_id
XML representation: The prop_id attribute.
Writing: Stores the text representation of PropID whenever the writer reaches this field.
property[@prop_id={self.PropID.toString}]/@class_name
XML representation: The class_name attribute.
Writing: Stores xmlClassName whenever the writer reaches this field.
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}]/@prop_name
XML representation: The prop_name attribute.
Writing: Stores PropName whenever the writer reaches this field.
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}][@prop_name={self.PropName}]/ListCountries/@rec_type
XML representation: The rec_type attribute.
Writing: Stores the literal text “TCountryIdList” whenever the writer reaches this field.
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}][@prop_name={self.PropName}]/ListCountries/HolidaysSet/@id
XML representation: The id attribute.
Writing: Stores the text representation of i when for each i from low (TCountryIdList) through high (TCountryIdList); (curSetID is greater than 0 or i is low (TCountryIdList)).
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}][@prop_name={self.PropName}]/ListCountries/HolidaysSet[@id={i.toString}]
XML representation: The text of the HolidaysSet[@id={i.toString}] element.
Writing: Stores the text representation of curSetID when for each i from low (TCountryIdList) through high (TCountryIdList); (curSetID is greater than 0 or i is low (TCountryIdList)).
Import: This routine does not read this field. See the inherited or enclosing implementation where applicable.
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}][@prop_name={self.PropName}]/SkipFirstOccurrence
XML representation: The text of the SkipFirstOccurrence element.
Writing: Stores the numeric value of SkipFirstOccurrence whenever the writer reaches this field.
Import: This routine does not read this field. See the inherited or enclosing implementation where applicable.
property[@prop_id={self.PropID.toString}][@class_name={self.xmlClassName}][@prop_name={self.PropName}]/SkipLastOccurrence
XML representation: The text of the SkipLastOccurrence element.
Writing: Stores the numeric value of SkipLastOccurrence whenever the writer reaches this field.
Import: This routine does not read this field. See the inherited or enclosing implementation where applicable.
Initialization and reset values
This type has no separate initializer in the supplied code. Its starting values come from its enclosing object, inherited initialization, or existing state. Relevant enclosing initializers are identified below.
Storage declarations relevant to interpretation
These are in-memory member and property types, not a list of mandatory XML children. They retain array bounds, fixed buffers and selector types. The field reference above defines what is actually serialized.
Name |
Declared type / bounds |
Kind |
SkipFirstOccurrence |
integer |
member |
SkipLastOccurrence |
integer |
member |
The Implementation toggle contains only TVarDates methods. Initializers and helpers belonging to other types are identified separately below. Shared XML-helper limitations are explained in Reading this reference.