Class: Icalendar::Calendar
Constant Summary
HasComponents::METHOD_MISSING_ADD_REGEX, HasComponents::METHOD_MISSING_X_FLAG_REGEX
Instance Attribute Summary
Attributes inherited from Component
#ical_name, #name, #parent
Instance Method Summary
collapse
Methods inherited from Component
#new_uid, parse, #to_ical
#add_component, #add_custom_component, #custom_component, included, #method_missing, #respond_to_missing?
#append_custom_property, #custom_property, included, #method_missing, #property, #respond_to_missing?, #valid?
Constructor Details
Returns a new instance of Calendar.
27
28
29
30
31
32
|
# File 'lib/icalendar/calendar.rb', line 27
def initialize
super 'calendar'
self.prodid = 'icalendar-ruby'
self.version = '2.0'
self.calscale = 'GREGORIAN'
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
in the class Icalendar::HasComponents
Instance Method Details
#add ⇒ Object
49
50
51
52
|
# File 'lib/icalendar/calendar.rb', line 49
def add
self.ip_method = 'ADD'
self
end
|
#cancel ⇒ Object
54
55
56
57
|
# File 'lib/icalendar/calendar.rb', line 54
def cancel
self.ip_method = 'CANCEL'
self
end
|
#counter ⇒ Object
64
65
66
67
|
# File 'lib/icalendar/calendar.rb', line 64
def counter
self.ip_method = 'COUNTER'
self
end
|
#decline_counter ⇒ Object
69
70
71
72
|
# File 'lib/icalendar/calendar.rb', line 69
def decline_counter
self.ip_method = 'DECLINECOUNTER'
self
end
|
#publish ⇒ Object
34
35
36
37
|
# File 'lib/icalendar/calendar.rb', line 34
def publish
self.ip_method = 'PUBLISH'
self
end
|
#refresh ⇒ Object
59
60
61
62
|
# File 'lib/icalendar/calendar.rb', line 59
def refresh
self.ip_method = 'REFRESH'
self
end
|
#reply ⇒ Object
44
45
46
47
|
# File 'lib/icalendar/calendar.rb', line 44
def reply
self.ip_method = 'REPLY'
self
end
|
#request ⇒ Object
39
40
41
42
|
# File 'lib/icalendar/calendar.rb', line 39
def request
self.ip_method = 'REQUEST'
self
end
|