def parse(pattern)
      raise(ISO8601::Errors::UnknownPattern, pattern) unless pattern.include?('/')

      @pattern = pattern
      subpatterns = pattern.split('/')

      raise(ISO8601::Errors::UnknownPattern, pattern) if subpatterns.size != 2

      fst = parse_start_subpattern(subpatterns.first)
      snd = parse_subpattern(subpatterns.last)
      @atoms = [fst, snd]
      @first, @last, @size = limits(@atoms)
    end
def parse(pattern)
      raise(ISO8601::Errors::UnknownPattern, pattern) unless pattern.include?('/')

      @pattern = pattern
      subpatterns = pattern.split('/')

      raise(ISO8601::Errors::UnknownPattern, pattern) if subpatterns.size != 2

      fst = parse_start_subpattern(subpatterns.first)
      snd = parse_subpattern(subpatterns.last)
      @atoms = [fst, snd]
      @first, @last, @size = limits(@atoms)
    end
Initialize a TimeInterval ISO8601 by a pattern. If you initialize it with
 a duration pattern, the second argument is mandatory because you need to
 specify an start/end point to calculate the interval.

 @param [String] pattern This parameter defines a full time interval.
     Valid patterns are defined in the ISO8601 as:
         * <start_time>/<end_time>
         * <start_time>/<duration>
         * <duration>/<end_time>

 @raise [ISO8601::Errors::UnknownPattern] If given pattern is not a valid
     ISO8601 pattern.