class TCal::Calendar::ICal

Overview

Generates an iCal calendar from a collection of MBTA Alerts. See RFC5545 for the iCal spec, and RFC7986 for additional properties.

Alerts can have an arbitrary set of periods. The equivalent iCal concept is RDATE;VALUE=PERIOD, but unfortunately most calendar apps don't support this part of the standard. Therefore each period is output as a separate event.

Defined in:

t_cal/calendar/ical.cr

Constructors

Instance Method Summary

Constructor methods inherited from class TCal::Calendar

new new

Constructor Detail

def self.new #

Creates a calendar instance.


[View source]

Instance Method Detail

def to_s(io : IO) : Nil #

Writes the iCal data to the specified IO.


[View source]