| 74 | } |
| 75 | |
| 76 | std::vector<openstudio::Date> ScheduleYear_Impl::dates() const { |
| 77 | std::vector<openstudio::Date> result; |
| 78 | |
| 79 | YearDescription yd = this->model().getUniqueModelObject<YearDescription>(); |
| 80 | |
| 81 | for (const auto& group : this->extensibleGroups()) { |
| 82 | OptionalUnsigned month = group.getUnsigned(0, true); |
| 83 | OptionalUnsigned day = group.getUnsigned(1, true); |
| 84 | |
| 85 | if (month && day) { |
| 86 | result.push_back(yd.makeDate(*month, *day)); |
| 87 | } else { |
| 88 | LOG(Error, "Could not read date " << group.groupIndex() << " in " << briefDescription() << "."); |
| 89 | } |
| 90 | } |
| 91 | |
| 92 | return result; |
| 93 | } |
| 94 | |
| 95 | std::vector<ScheduleWeek> ScheduleYear_Impl::scheduleWeeks() const { |
| 96 | std::vector<ScheduleWeek> result; |