CreateTransitionGroupToPeriod method

TimeZoneTransitionGroup CreateTransitionGroupToPeriod(
  1. TimeZonePeriod timeZonePeriod
)
Adds a transition group with a single transition to the specified period. The time zone period.

Implementation

/* private */
TimeZoneTransitionGroup CreateTransitionGroupToPeriod(
    TimeZonePeriod timeZonePeriod) {
  TimeZoneTransition transitionToPeriod =
      new TimeZoneTransition.withTimeZonePeriod(this, timeZonePeriod);

  TimeZoneTransitionGroup transitionGroup =
      new TimeZoneTransitionGroup.withId(
          this, this._transitionGroups.length.toString());
  transitionGroup.Transitions.add(transitionToPeriod);

  this._transitionGroups[transitionGroup.Id] = transitionGroup;

  return transitionGroup;
}