micahwedemeyer-ri_cal 0.8.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (173) hide show
  1. data/.rvmrc +2 -0
  2. data/Gemfile +7 -0
  3. data/Gemfile.lock +21 -0
  4. data/History.txt +402 -0
  5. data/Manifest.txt +161 -0
  6. data/README.txt +410 -0
  7. data/Rakefile +66 -0
  8. data/VERSION +1 -0
  9. data/bin/ri_cal +8 -0
  10. data/component_attributes/alarm.yml +10 -0
  11. data/component_attributes/calendar.yml +4 -0
  12. data/component_attributes/component_property_defs.yml +180 -0
  13. data/component_attributes/event.yml +45 -0
  14. data/component_attributes/freebusy.yml +16 -0
  15. data/component_attributes/journal.yml +35 -0
  16. data/component_attributes/timezone.yml +3 -0
  17. data/component_attributes/timezone_period.yml +11 -0
  18. data/component_attributes/todo.yml +46 -0
  19. data/copyrights.txt +1 -0
  20. data/docs/draft-ietf-calsify-2446bis-08.txt +7280 -0
  21. data/docs/draft-ietf-calsify-rfc2445bis-09.txt +10416 -0
  22. data/docs/incrementers.txt +7 -0
  23. data/docs/rfc2445.pdf +0 -0
  24. data/lib/ri_cal/component/alarm.rb +19 -0
  25. data/lib/ri_cal/component/calendar.rb +257 -0
  26. data/lib/ri_cal/component/event.rb +58 -0
  27. data/lib/ri_cal/component/freebusy.rb +16 -0
  28. data/lib/ri_cal/component/journal.rb +27 -0
  29. data/lib/ri_cal/component/non_standard.rb +33 -0
  30. data/lib/ri_cal/component/t_z_info_timezone.rb +153 -0
  31. data/lib/ri_cal/component/timezone/daylight_period.rb +25 -0
  32. data/lib/ri_cal/component/timezone/standard_period.rb +23 -0
  33. data/lib/ri_cal/component/timezone/timezone_period.rb +76 -0
  34. data/lib/ri_cal/component/timezone.rb +197 -0
  35. data/lib/ri_cal/component/todo.rb +42 -0
  36. data/lib/ri_cal/component.rb +256 -0
  37. data/lib/ri_cal/core_extensions/array/conversions.rb +15 -0
  38. data/lib/ri_cal/core_extensions/array.rb +7 -0
  39. data/lib/ri_cal/core_extensions/date/conversions.rb +56 -0
  40. data/lib/ri_cal/core_extensions/date.rb +13 -0
  41. data/lib/ri_cal/core_extensions/date_time/conversions.rb +50 -0
  42. data/lib/ri_cal/core_extensions/date_time.rb +15 -0
  43. data/lib/ri_cal/core_extensions/object/conversions.rb +20 -0
  44. data/lib/ri_cal/core_extensions/object.rb +8 -0
  45. data/lib/ri_cal/core_extensions/string/conversions.rb +57 -0
  46. data/lib/ri_cal/core_extensions/string.rb +8 -0
  47. data/lib/ri_cal/core_extensions/time/calculations.rb +153 -0
  48. data/lib/ri_cal/core_extensions/time/conversions.rb +42 -0
  49. data/lib/ri_cal/core_extensions/time/tzid_access.rb +50 -0
  50. data/lib/ri_cal/core_extensions/time/week_day_predicates.rb +55 -0
  51. data/lib/ri_cal/core_extensions/time.rb +14 -0
  52. data/lib/ri_cal/core_extensions.rb +11 -0
  53. data/lib/ri_cal/fast_date_time.rb +234 -0
  54. data/lib/ri_cal/floating_timezone.rb +32 -0
  55. data/lib/ri_cal/invalid_property_value.rb +8 -0
  56. data/lib/ri_cal/invalid_timezone_identifier.rb +20 -0
  57. data/lib/ri_cal/occurrence_enumerator.rb +265 -0
  58. data/lib/ri_cal/occurrence_period.rb +17 -0
  59. data/lib/ri_cal/parser.rb +145 -0
  60. data/lib/ri_cal/properties/alarm.rb +390 -0
  61. data/lib/ri_cal/properties/calendar.rb +164 -0
  62. data/lib/ri_cal/properties/event.rb +1523 -0
  63. data/lib/ri_cal/properties/freebusy.rb +593 -0
  64. data/lib/ri_cal/properties/journal.rb +1237 -0
  65. data/lib/ri_cal/properties/timezone.rb +150 -0
  66. data/lib/ri_cal/properties/timezone_period.rb +416 -0
  67. data/lib/ri_cal/properties/todo.rb +1559 -0
  68. data/lib/ri_cal/properties.rb +12 -0
  69. data/lib/ri_cal/property_value/array.rb +27 -0
  70. data/lib/ri_cal/property_value/cal_address.rb +11 -0
  71. data/lib/ri_cal/property_value/date.rb +184 -0
  72. data/lib/ri_cal/property_value/date_time/additive_methods.rb +44 -0
  73. data/lib/ri_cal/property_value/date_time/time_machine.rb +159 -0
  74. data/lib/ri_cal/property_value/date_time/timezone_support.rb +100 -0
  75. data/lib/ri_cal/property_value/date_time.rb +359 -0
  76. data/lib/ri_cal/property_value/duration.rb +110 -0
  77. data/lib/ri_cal/property_value/geo.rb +11 -0
  78. data/lib/ri_cal/property_value/integer.rb +12 -0
  79. data/lib/ri_cal/property_value/occurrence_list.rb +144 -0
  80. data/lib/ri_cal/property_value/period.rb +86 -0
  81. data/lib/ri_cal/property_value/recurrence_rule/enumeration_support_methods.rb +100 -0
  82. data/lib/ri_cal/property_value/recurrence_rule/enumerator.rb +79 -0
  83. data/lib/ri_cal/property_value/recurrence_rule/initialization_methods.rb +148 -0
  84. data/lib/ri_cal/property_value/recurrence_rule/negative_setpos_enumerator.rb +53 -0
  85. data/lib/ri_cal/property_value/recurrence_rule/numbered_span.rb +31 -0
  86. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_day_incrementer.rb +86 -0
  87. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_hour_incrementer.rb +31 -0
  88. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_minute_incrementer.rb +32 -0
  89. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_month_incrementer.rb +52 -0
  90. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_monthday_incrementer.rb +31 -0
  91. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_numbered_day_incrementer.rb +38 -0
  92. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_second_incrementer.rb +32 -0
  93. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_weekno_incrementer.rb +69 -0
  94. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_yearday_incrementer.rb +31 -0
  95. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/daily_incrementer.rb +28 -0
  96. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/frequency_incrementer.rb +80 -0
  97. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/hourly_incrementer.rb +23 -0
  98. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/list_incrementer.rb +106 -0
  99. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/minutely_incrementer.rb +23 -0
  100. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/monthly_incrementer.rb +33 -0
  101. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/null_sub_cycle_incrementer.rb +43 -0
  102. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/secondly_incrementer.rb +28 -0
  103. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/weekly_incrementer.rb +37 -0
  104. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/yearly_incrementer.rb +57 -0
  105. data/lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer.rb +135 -0
  106. data/lib/ri_cal/property_value/recurrence_rule/recurring_day.rb +131 -0
  107. data/lib/ri_cal/property_value/recurrence_rule/recurring_month_day.rb +64 -0
  108. data/lib/ri_cal/property_value/recurrence_rule/recurring_numbered_week.rb +33 -0
  109. data/lib/ri_cal/property_value/recurrence_rule/recurring_year_day.rb +53 -0
  110. data/lib/ri_cal/property_value/recurrence_rule/time_manipulation.rb +42 -0
  111. data/lib/ri_cal/property_value/recurrence_rule/validations.rb +125 -0
  112. data/lib/ri_cal/property_value/recurrence_rule.rb +154 -0
  113. data/lib/ri_cal/property_value/text.rb +44 -0
  114. data/lib/ri_cal/property_value/uri.rb +11 -0
  115. data/lib/ri_cal/property_value/utc_offset.rb +33 -0
  116. data/lib/ri_cal/property_value/zulu_date_time.rb +34 -0
  117. data/lib/ri_cal/property_value.rb +159 -0
  118. data/lib/ri_cal/required_timezones.rb +55 -0
  119. data/lib/ri_cal.rb +187 -0
  120. data/micahwedemeyer-ri_cal.gemspec +227 -0
  121. data/parked_specs/ri_cal/claudio_a_bug_spec.rb +100 -0
  122. data/performance/empty_propval/subject.rb +43 -0
  123. data/performance/paris_eastern/subject.rb +90 -0
  124. data/performance/penultimate_weekday/subject.rb +15 -0
  125. data/performance/psm_big_enum/ical.ics +3171 -0
  126. data/performance/psm_big_enum/subject.rb +16 -0
  127. data/performance/utah_cycling/subject.rb +55 -0
  128. data/sample_ical_files/from_ical_dot_app/test1.ics +38 -0
  129. data/script/benchmark_subject +23 -0
  130. data/script/console +10 -0
  131. data/script/destroy +14 -0
  132. data/script/generate +14 -0
  133. data/script/profile_subject +29 -0
  134. data/script/txt2html +71 -0
  135. data/spec/ri_cal/bugreports_spec.rb +287 -0
  136. data/spec/ri_cal/component/alarm_spec.rb +12 -0
  137. data/spec/ri_cal/component/calendar_spec.rb +88 -0
  138. data/spec/ri_cal/component/event_spec.rb +735 -0
  139. data/spec/ri_cal/component/freebusy_spec.rb +12 -0
  140. data/spec/ri_cal/component/journal_spec.rb +37 -0
  141. data/spec/ri_cal/component/t_z_info_timezone_spec.rb +60 -0
  142. data/spec/ri_cal/component/timezone_spec.rb +236 -0
  143. data/spec/ri_cal/component/todo_spec.rb +112 -0
  144. data/spec/ri_cal/component_spec.rb +224 -0
  145. data/spec/ri_cal/core_extensions/string/conversions_spec.rb +78 -0
  146. data/spec/ri_cal/core_extensions/time/calculations_spec.rb +188 -0
  147. data/spec/ri_cal/core_extensions/time/week_day_predicates_spec.rb +45 -0
  148. data/spec/ri_cal/fast_date_time_spec.rb +77 -0
  149. data/spec/ri_cal/inf_loop_spec.rb +78 -0
  150. data/spec/ri_cal/occurrence_enumerator_spec.rb +611 -0
  151. data/spec/ri_cal/parser_spec.rb +337 -0
  152. data/spec/ri_cal/property_value/date_spec.rb +53 -0
  153. data/spec/ri_cal/property_value/date_time_spec.rb +383 -0
  154. data/spec/ri_cal/property_value/duration_spec.rb +126 -0
  155. data/spec/ri_cal/property_value/occurrence_list_spec.rb +72 -0
  156. data/spec/ri_cal/property_value/period_spec.rb +63 -0
  157. data/spec/ri_cal/property_value/recurrence_rule/recurring_year_day_spec.rb +21 -0
  158. data/spec/ri_cal/property_value/recurrence_rule_spec.rb +1814 -0
  159. data/spec/ri_cal/property_value/text_spec.rb +25 -0
  160. data/spec/ri_cal/property_value/utc_offset_spec.rb +48 -0
  161. data/spec/ri_cal/property_value_spec.rb +125 -0
  162. data/spec/ri_cal/required_timezones_spec.rb +67 -0
  163. data/spec/ri_cal_spec.rb +53 -0
  164. data/spec/spec.opts +4 -0
  165. data/spec/spec_helper.rb +50 -0
  166. data/tasks/gem_loader/load_active_support.rb +3 -0
  167. data/tasks/gem_loader/load_tzinfo_gem.rb +2 -0
  168. data/tasks/ri_cal.rake +412 -0
  169. data/tasks/spec.rake +102 -0
  170. data/website/images/rubytrends.png +0 -0
  171. data/website/javascripts/rounded_corners_lite.inc.js +285 -0
  172. data/website/stylesheets/screen.css +159 -0
  173. metadata +307 -0
@@ -0,0 +1,227 @@
1
+ # Generated by jeweler
2
+ # DO NOT EDIT THIS FILE DIRECTLY
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
+ # -*- encoding: utf-8 -*-
5
+
6
+ Gem::Specification.new do |s|
7
+ s.name = %q{micahwedemeyer-ri_cal}
8
+ s.version = "0.8.9"
9
+
10
+ s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
+ s.authors = ["Rick DeNatale"]
12
+ s.date = %q{2011-07-02}
13
+ s.default_executable = %q{ri_cal}
14
+ s.description = %q{A new Ruby implementation of RFC2445 iCalendar.
15
+
16
+ The existing Ruby iCalendar libraries (e.g. icalendar, vpim) provide for parsing and generating icalendar files,
17
+ but do not support important things like enumerating occurrences of repeating events.
18
+
19
+ This is a clean-slate implementation of RFC2445.
20
+
21
+ A Google group for discussion of this library has been set up http://groups.google.com/group/rical_gem
22
+ }
23
+ s.email = %q{rick.denatale@gmail.com}
24
+ s.executables = ["ri_cal"]
25
+ s.extra_rdoc_files = [
26
+ "History.txt",
27
+ "README.txt",
28
+ "copyrights.txt"
29
+ ]
30
+ s.files = [
31
+ "History.txt",
32
+ "Manifest.txt",
33
+ "README.txt",
34
+ "Rakefile",
35
+ "VERSION",
36
+ "bin/ri_cal",
37
+ "component_attributes/alarm.yml",
38
+ "component_attributes/calendar.yml",
39
+ "component_attributes/component_property_defs.yml",
40
+ "component_attributes/event.yml",
41
+ "component_attributes/freebusy.yml",
42
+ "component_attributes/journal.yml",
43
+ "component_attributes/timezone.yml",
44
+ "component_attributes/timezone_period.yml",
45
+ "component_attributes/todo.yml",
46
+ "copyrights.txt",
47
+ "docs/draft-ietf-calsify-2446bis-08.txt",
48
+ "docs/draft-ietf-calsify-rfc2445bis-09.txt",
49
+ "docs/incrementers.txt",
50
+ "docs/rfc2445.pdf",
51
+ "lib/ri_cal.rb",
52
+ "lib/ri_cal/component.rb",
53
+ "lib/ri_cal/component/alarm.rb",
54
+ "lib/ri_cal/component/calendar.rb",
55
+ "lib/ri_cal/component/event.rb",
56
+ "lib/ri_cal/component/freebusy.rb",
57
+ "lib/ri_cal/component/journal.rb",
58
+ "lib/ri_cal/component/non_standard.rb",
59
+ "lib/ri_cal/component/t_z_info_timezone.rb",
60
+ "lib/ri_cal/component/timezone.rb",
61
+ "lib/ri_cal/component/timezone/daylight_period.rb",
62
+ "lib/ri_cal/component/timezone/standard_period.rb",
63
+ "lib/ri_cal/component/timezone/timezone_period.rb",
64
+ "lib/ri_cal/component/todo.rb",
65
+ "lib/ri_cal/core_extensions.rb",
66
+ "lib/ri_cal/core_extensions/array.rb",
67
+ "lib/ri_cal/core_extensions/array/conversions.rb",
68
+ "lib/ri_cal/core_extensions/date.rb",
69
+ "lib/ri_cal/core_extensions/date/conversions.rb",
70
+ "lib/ri_cal/core_extensions/date_time.rb",
71
+ "lib/ri_cal/core_extensions/date_time/conversions.rb",
72
+ "lib/ri_cal/core_extensions/object.rb",
73
+ "lib/ri_cal/core_extensions/object/conversions.rb",
74
+ "lib/ri_cal/core_extensions/string.rb",
75
+ "lib/ri_cal/core_extensions/string/conversions.rb",
76
+ "lib/ri_cal/core_extensions/time.rb",
77
+ "lib/ri_cal/core_extensions/time/calculations.rb",
78
+ "lib/ri_cal/core_extensions/time/conversions.rb",
79
+ "lib/ri_cal/core_extensions/time/tzid_access.rb",
80
+ "lib/ri_cal/core_extensions/time/week_day_predicates.rb",
81
+ "lib/ri_cal/fast_date_time.rb",
82
+ "lib/ri_cal/floating_timezone.rb",
83
+ "lib/ri_cal/invalid_property_value.rb",
84
+ "lib/ri_cal/invalid_timezone_identifier.rb",
85
+ "lib/ri_cal/occurrence_enumerator.rb",
86
+ "lib/ri_cal/occurrence_period.rb",
87
+ "lib/ri_cal/parser.rb",
88
+ "lib/ri_cal/properties.rb",
89
+ "lib/ri_cal/properties/alarm.rb",
90
+ "lib/ri_cal/properties/calendar.rb",
91
+ "lib/ri_cal/properties/event.rb",
92
+ "lib/ri_cal/properties/freebusy.rb",
93
+ "lib/ri_cal/properties/journal.rb",
94
+ "lib/ri_cal/properties/timezone.rb",
95
+ "lib/ri_cal/properties/timezone_period.rb",
96
+ "lib/ri_cal/properties/todo.rb",
97
+ "lib/ri_cal/property_value.rb",
98
+ "lib/ri_cal/property_value/array.rb",
99
+ "lib/ri_cal/property_value/cal_address.rb",
100
+ "lib/ri_cal/property_value/date.rb",
101
+ "lib/ri_cal/property_value/date_time.rb",
102
+ "lib/ri_cal/property_value/date_time/additive_methods.rb",
103
+ "lib/ri_cal/property_value/date_time/time_machine.rb",
104
+ "lib/ri_cal/property_value/date_time/timezone_support.rb",
105
+ "lib/ri_cal/property_value/duration.rb",
106
+ "lib/ri_cal/property_value/geo.rb",
107
+ "lib/ri_cal/property_value/integer.rb",
108
+ "lib/ri_cal/property_value/occurrence_list.rb",
109
+ "lib/ri_cal/property_value/period.rb",
110
+ "lib/ri_cal/property_value/recurrence_rule.rb",
111
+ "lib/ri_cal/property_value/recurrence_rule/enumeration_support_methods.rb",
112
+ "lib/ri_cal/property_value/recurrence_rule/enumerator.rb",
113
+ "lib/ri_cal/property_value/recurrence_rule/initialization_methods.rb",
114
+ "lib/ri_cal/property_value/recurrence_rule/negative_setpos_enumerator.rb",
115
+ "lib/ri_cal/property_value/recurrence_rule/numbered_span.rb",
116
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer.rb",
117
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_day_incrementer.rb",
118
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_hour_incrementer.rb",
119
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_minute_incrementer.rb",
120
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_month_incrementer.rb",
121
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_monthday_incrementer.rb",
122
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_numbered_day_incrementer.rb",
123
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_second_incrementer.rb",
124
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_weekno_incrementer.rb",
125
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/by_yearday_incrementer.rb",
126
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/daily_incrementer.rb",
127
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/frequency_incrementer.rb",
128
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/hourly_incrementer.rb",
129
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/list_incrementer.rb",
130
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/minutely_incrementer.rb",
131
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/monthly_incrementer.rb",
132
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/null_sub_cycle_incrementer.rb",
133
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/secondly_incrementer.rb",
134
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/weekly_incrementer.rb",
135
+ "lib/ri_cal/property_value/recurrence_rule/occurrence_incrementer/yearly_incrementer.rb",
136
+ "lib/ri_cal/property_value/recurrence_rule/recurring_day.rb",
137
+ "lib/ri_cal/property_value/recurrence_rule/recurring_month_day.rb",
138
+ "lib/ri_cal/property_value/recurrence_rule/recurring_numbered_week.rb",
139
+ "lib/ri_cal/property_value/recurrence_rule/recurring_year_day.rb",
140
+ "lib/ri_cal/property_value/recurrence_rule/time_manipulation.rb",
141
+ "lib/ri_cal/property_value/recurrence_rule/validations.rb",
142
+ "lib/ri_cal/property_value/text.rb",
143
+ "lib/ri_cal/property_value/uri.rb",
144
+ "lib/ri_cal/property_value/utc_offset.rb",
145
+ "lib/ri_cal/property_value/zulu_date_time.rb",
146
+ "lib/ri_cal/required_timezones.rb",
147
+ "parked_specs/ri_cal/claudio_a_bug_spec.rb",
148
+ "performance/empty_propval/subject.rb",
149
+ "performance/paris_eastern/subject.rb",
150
+ "performance/penultimate_weekday/subject.rb",
151
+ "performance/psm_big_enum/ical.ics",
152
+ "performance/psm_big_enum/subject.rb",
153
+ "performance/utah_cycling/subject.rb",
154
+ "ri_cal.gemspec",
155
+ "sample_ical_files/from_ical_dot_app/test1.ics",
156
+ "script/benchmark_subject",
157
+ "script/console",
158
+ "script/destroy",
159
+ "script/generate",
160
+ "script/profile_subject",
161
+ "script/txt2html",
162
+ "spec/ri_cal/bugreports_spec.rb",
163
+ "spec/ri_cal/component/alarm_spec.rb",
164
+ "spec/ri_cal/component/calendar_spec.rb",
165
+ "spec/ri_cal/component/event_spec.rb",
166
+ "spec/ri_cal/component/freebusy_spec.rb",
167
+ "spec/ri_cal/component/journal_spec.rb",
168
+ "spec/ri_cal/component/t_z_info_timezone_spec.rb",
169
+ "spec/ri_cal/component/timezone_spec.rb",
170
+ "spec/ri_cal/component/todo_spec.rb",
171
+ "spec/ri_cal/component_spec.rb",
172
+ "spec/ri_cal/core_extensions/string/conversions_spec.rb",
173
+ "spec/ri_cal/core_extensions/time/calculations_spec.rb",
174
+ "spec/ri_cal/core_extensions/time/week_day_predicates_spec.rb",
175
+ "spec/ri_cal/fast_date_time_spec.rb",
176
+ "spec/ri_cal/inf_loop_spec.rb",
177
+ "spec/ri_cal/occurrence_enumerator_spec.rb",
178
+ "spec/ri_cal/parser_spec.rb",
179
+ "spec/ri_cal/property_value/date_spec.rb",
180
+ "spec/ri_cal/property_value/date_time_spec.rb",
181
+ "spec/ri_cal/property_value/duration_spec.rb",
182
+ "spec/ri_cal/property_value/occurrence_list_spec.rb",
183
+ "spec/ri_cal/property_value/period_spec.rb",
184
+ "spec/ri_cal/property_value/recurrence_rule/recurring_year_day_spec.rb",
185
+ "spec/ri_cal/property_value/recurrence_rule_spec.rb",
186
+ "spec/ri_cal/property_value/text_spec.rb",
187
+ "spec/ri_cal/property_value/utc_offset_spec.rb",
188
+ "spec/ri_cal/property_value_spec.rb",
189
+ "spec/ri_cal/required_timezones_spec.rb",
190
+ "spec/ri_cal_spec.rb",
191
+ "spec/spec.opts",
192
+ "spec/spec_helper.rb",
193
+ "tasks/gem_loader/load_active_support.rb",
194
+ "tasks/gem_loader/load_tzinfo_gem.rb",
195
+ "tasks/ri_cal.rake",
196
+ "tasks/spec.rake",
197
+ "website/images/rubytrends.png",
198
+ "website/javascripts/rounded_corners_lite.inc.js",
199
+ "website/stylesheets/screen.css"
200
+ ]
201
+ s.homepage = %q{http://github.com/rubyredrick/ri_cal}
202
+ s.require_paths = ["lib"]
203
+ s.rubygems_version = %q{1.6.2}
204
+ s.summary = %q{a new implementation of RFC2445 in Ruby}
205
+
206
+ if s.respond_to? :specification_version then
207
+ s.specification_version = 3
208
+
209
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
210
+ s.add_runtime_dependency(%q<bundler>, ["= 1.0.15"])
211
+ s.add_runtime_dependency(%q<jeweler>, ["= 1.6.3"])
212
+ s.add_runtime_dependency(%q<gemcutter>, ["= 0.7.0"])
213
+ s.add_runtime_dependency(%q<ad_agency>, ["= 0.1.2"])
214
+ else
215
+ s.add_dependency(%q<bundler>, ["= 1.0.15"])
216
+ s.add_dependency(%q<jeweler>, ["= 1.6.3"])
217
+ s.add_dependency(%q<gemcutter>, ["= 0.7.0"])
218
+ s.add_dependency(%q<ad_agency>, ["= 0.1.2"])
219
+ end
220
+ else
221
+ s.add_dependency(%q<bundler>, ["= 1.0.15"])
222
+ s.add_dependency(%q<jeweler>, ["= 1.6.3"])
223
+ s.add_dependency(%q<gemcutter>, ["= 0.7.0"])
224
+ s.add_dependency(%q<ad_agency>, ["= 0.1.2"])
225
+ end
226
+ end
227
+
@@ -0,0 +1,100 @@
1
+ #- ©2009 Rick DeNatale, All rights reserved. Refer to the file README.txt for the license
2
+
3
+ require 'rubygems'
4
+ require File.join(File.dirname(__FILE__), %w[.. spec_helper])
5
+
6
+ describe "RiCal TimeZone problem" do
7
+ it "should keep the original calendar timezone intact" do
8
+ original_calendar = RiCal.parse_string(original_calendar_contents).first
9
+ puts "*"*40
10
+ puts original_calendar
11
+ puts "*"*40
12
+ reply_calendar = reply original_calendar
13
+ #reply_calendar = RiCal.parse_string(reply_calendar_contents).first
14
+ puts reply_calendar
15
+ puts "*"*40
16
+
17
+ original_event = original_calendar.events.first
18
+ reply_event = reply_calendar.events.first
19
+ reply_event.start_time.to_s.should == original_event.start_time.to_s
20
+ end
21
+ end
22
+
23
+ private
24
+
25
+ # This is the calendar contents generated when we send the message >>#reply to the original calendar.
26
+ def reply_calendar_contents
27
+ "BEGIN:VCALENDAR
28
+ PRODID;X-RICAL-TZSOURCE=TZINFO:-//com.denhaven2/NONSGML ri_cal gem//EN
29
+ CALSCALE:GREGORIAN
30
+ VERSION:2.0
31
+ METHOD:REPLY
32
+ BEGIN:VTIMEZONE
33
+ TZID;X-RICAL-TZSOURCE=TZINFO:America/Argentina/Buenos_Aires
34
+ BEGIN:STANDARD
35
+ DTSTART:20090314T230000
36
+ RDATE:20090314T230000
37
+ TZOFFSETFROM:-0200
38
+ TZOFFSETTO:-0300
39
+ TZNAME:ART
40
+ END:STANDARD
41
+ END:VTIMEZONE
42
+ BEGIN:VEVENT
43
+ CREATED;VALUE=DATE-TIME:20091217T155557Z
44
+ DTEND;TZID=America/Argentina/Buenos_Aires;VALUE=DATE-TIME:20091227T010000
45
+ STATUS:CONFIRMED
46
+ LAST-MODIFIED;TZID=America/Argentina/Buenos_Aires;VALUE=DATE-TIME:2009121
47
+ 7T173400
48
+ DTSTART;TZID=America/Argentina/Buenos_Aires;VALUE=DATE-TIME:20091227T0000
49
+ 00
50
+ ATTENDEE;CN=PoketyPoke;PARTSTAT=ACCEPTED;ROLE=REQ-PARTICIPANT:barbarazopp
51
+ o@gmail.com
52
+ UID:1693CA3B-C528-4E5A-87FB-CDFAEC0EC662
53
+ ORGANIZER:mailto:nasif.lucas@gmail.com
54
+ DESCRIPTION:
55
+ SUMMARY:testing.. Event
56
+ SEQUENCE:3
57
+ LOCATION:
58
+ END:VEVENT
59
+ END:VCALENDAR".strip
60
+ end
61
+
62
+ def original_calendar_contents
63
+ "BEGIN:VCALENDAR\nPRODID:-//Apple Inc.//iCal 4.0.1//EN\nCALSCALE:GREGORIAN\nVERSION:2.0\nMETHOD:REQUEST\nBEGIN:VEVENT\nTRANSP:TRANSPARENT\nDTSTAMP;VALUE=DATE-TIME:20091217T155800Z\nCREATED;VALUE=DATE-TIME:20091217T155557Z\nDTEND;TZID=America/Argentina/Buenos_Aires;VALUE=DATE-TIME:20091227T010000\nDTSTART;TZID=America/Argentina/Buenos_Aires;VALUE=DATE-TIME:20091227T0000\n 00\nATTENDEE;CN=Lucas Nasif;CUTYPE=INDIVIDUAL;PARTSTAT=ACCEPTED:mailto:nasif.\n lucas@gmail.com\nATTENDEE;CN=barbarazoppo@gmail.com;CUTYPE=INDIVIDUAL;EMAIL=barbarazoppo@g\n mail.com;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT;RSVP=TRUE:mailto:bar\n barazoppo@gmail.com\nUID:1693CA3B-C528-4E5A-87FB-CDFAEC0EC662\nORGANIZER;CN=Lucas Nasif:mailto:nasif.lucas@gmail.com\nSUMMARY:testing.. Event\nSEQUENCE:3\nEND:VEVENT\nBEGIN:VTIMEZONE\nTZID:America/Argentina/Buenos_Aires\nBEGIN:STANDARD\nTZOFFSETTO:-0300\nDTSTART;VALUE=DATE-TIME:20080316T000000\nRRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=3SU\nTZOFFSETFROM:-0200\nTZNAME:GMT-03:00\nEND:STANDARD\nBEGIN:DAYLIGHT\nTZOFFSETTO:-0200\nDTSTART;VALUE=DATE-TIME:20081019T000000\nRRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=3SU\nTZOFFSETFROM:-0300\nTZNAME:GMT-02:00\nEND:DAYLIGHT\nEND:VTIMEZONE\nEND:VCALENDAR\n".strip
64
+ end
65
+
66
+ def reply(original_calendar)
67
+ icalendar = RiCal.Calendar do | calendar |
68
+
69
+ calendar.icalendar_method = "REPLY"
70
+ calendar.default_tzid = original_calendar.default_tzid
71
+
72
+ calendar.event do | event |
73
+
74
+ original_event = original_calendar.events.first
75
+ event.created = original_event.created
76
+ event.dtstart = original_event.start_time
77
+ event.dtend = original_event.finish_time
78
+ event.organizer = original_event.organizer
79
+ event.location = original_event.location.to_s
80
+ event.uid_property = original_event.uid_property
81
+
82
+ options = {'ROLE' => 'REQ-PARTICIPANT',
83
+ 'PARTSTAT' => 'ACCEPTED',
84
+ 'CN' => 'SomeName...'}
85
+
86
+ attendee_property = RiCal::PropertyValue::CalAddress.new(nil,
87
+ :value => @attendant,
88
+ :params => options)
89
+
90
+ event.attendee_property = attendee_property
91
+ event.description = original_event.description.to_s
92
+ event.summary = original_event.summary.to_s
93
+
94
+ event.sequence_property = original_event.sequence_property
95
+ event.status = "CONFIRMED"
96
+ event.last_modified = DateTime.parse(Time.now.to_s)
97
+ end
98
+ end
99
+ icalendar
100
+ end
@@ -0,0 +1,43 @@
1
+ class Subject
2
+ def initialize(out=STDOUT)
3
+ cals = RiCal.parse_string <<-END_OF_DATA
4
+ BEGIN:VCALENDAR
5
+ METHOD:REQUEST
6
+ PRODID:Microsoft CDO for Microsoft Exchange
7
+ VERSION:2.0
8
+ BEGIN:VTIMEZONE
9
+ TZID:(GMT-05.00) Eastern Time (US & Canada)
10
+ X-MICROSOFT-CDO-TZID:10
11
+ BEGIN:STANDARD
12
+ DTSTART:16010101T020000
13
+ TZOFFSETFROM:-0400
14
+ TZOFFSETTO:-0500
15
+ RRULE:FREQ=YEARLY;WKST=MO;INTERVAL=1;BYMONTH=11;BYDAY=1SU
16
+ END:STANDARD
17
+ BEGIN:DAYLIGHT
18
+ DTSTART:16010101T020000
19
+ TZOFFSETFROM:-0500
20
+ TZOFFSETTO:-0400
21
+ RRULE:FREQ=YEARLY;WKST=MO;INTERVAL=1;BYMONTH=3;BYDAY=2SU
22
+ END:DAYLIGHT
23
+ END:VTIMEZONE
24
+ BEGIN:VEVENT
25
+ DTSTAMP:20090724T143205Z
26
+ DTSTART;TZID="(GMT-05.00) Eastern Time (US & Canada)":20090804T120000
27
+ SUMMARY:FW: ALL HANDS MEETING
28
+ DTEND;TZID="(GMT-05.00) Eastern Time (US & Canada)":20090804T133000
29
+ DESCRIPTION:Some event
30
+ END:VEVENT
31
+ END:VCALENDAR
32
+ END_OF_DATA
33
+
34
+ cal = cals.first
35
+ @event = cal.events.first
36
+ end
37
+
38
+ def run
39
+ puts "start"
40
+ @event.dtstart
41
+ puts "done"
42
+ end
43
+ end
@@ -0,0 +1,90 @@
1
+ class Subject
2
+ def initialize(out=STDOUT)
3
+ cals = RiCal.parse_string <<-END_OF_DATA
4
+ BEGIN:VCALENDAR
5
+ METHOD:PUBLISH
6
+ X-WR-TIMEZONE:America/New_York
7
+ PRODID:-//Apple Inc.//iCal 3.0//EN
8
+ CALSCALE:GREGORIAN
9
+ X-WR-CALNAME:Test
10
+ VERSION:2.0
11
+ X-WR-RELCALID:58DB0663-196B-4B6B-A05A-A53049661280
12
+ X-APPLE-CALENDAR-COLOR:#0252D4
13
+ BEGIN:VTIMEZONE
14
+ TZID:Europe/Paris
15
+ BEGIN:DAYLIGHT
16
+ TZOFFSETFROM:+0100
17
+ TZOFFSETTO:+0200
18
+ DTSTART:19810329T020000
19
+ RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
20
+ TZNAME:CEST
21
+ END:DAYLIGHT
22
+ BEGIN:STANDARD
23
+ TZOFFSETFROM:+0200
24
+ TZOFFSETTO:+0100
25
+ DTSTART:19961027T030000
26
+ RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
27
+ TZNAME:CET
28
+ END:STANDARD
29
+ END:VTIMEZONE
30
+ BEGIN:VTIMEZONE
31
+ TZID:US/Eastern
32
+ BEGIN:DAYLIGHT
33
+ TZOFFSETFROM:-0500
34
+ TZOFFSETTO:-0400
35
+ DTSTART:20070311T020000
36
+ RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=2SU
37
+ TZNAME:EDT
38
+ END:DAYLIGHT
39
+ BEGIN:STANDARD
40
+ TZOFFSETFROM:-0400
41
+ TZOFFSETTO:-0500
42
+ DTSTART:20071104T020000
43
+ RRULE:FREQ=YEARLY;BYMONTH=11;BYDAY=1SU
44
+ TZNAME:EST
45
+ END:STANDARD
46
+ END:VTIMEZONE
47
+ BEGIN:VEVENT
48
+ SEQUENCE:3
49
+ TRANSP:OPAQUE
50
+ UID:AC2EFB19-A8A8-49EF-929F-CA0975374ED6
51
+ DTSTART:20090501T000000Z
52
+ DTSTAMP:20090501T174405Z
53
+ SUMMARY:UTC Event
54
+ CREATED:20090501T174347Z
55
+ DTEND:20090501T010000Z
56
+ END:VEVENT
57
+ BEGIN:VEVENT
58
+ SEQUENCE:2
59
+ TRANSP:OPAQUE
60
+ UID:A5517A09-C53E-4E1F-A642-EA47680BF2B6
61
+ DTSTART;TZID=US/Eastern:20090430T140000
62
+ DTSTAMP:20090501T174428Z
63
+ SUMMARY:Eastern Event
64
+ CREATED:20090501T174415Z
65
+ DTEND;TZID=US/Eastern:20090430T150000
66
+ END:VEVENT
67
+ BEGIN:VEVENT
68
+ SEQUENCE:3
69
+ TRANSP:OPAQUE
70
+ UID:B5024763-9197-4A60-A96E-D8D59D578BB2
71
+ DTSTART;TZID=Europe/Paris:20090430T140000
72
+ DTSTAMP:20090501T174509Z
73
+ SUMMARY:Paris Event
74
+ CREATED:20090501T174439Z
75
+ DTEND;TZID=Europe/Paris:20090430T150000
76
+ END:VEVENT
77
+ END:VCALENDAR
78
+ END_OF_DATA
79
+
80
+ cal = cals.first
81
+ event = cal.events.find {|event| event.summary == "Paris Event"}
82
+ @date_time = event.dtstart_property
83
+ end
84
+
85
+ def run
86
+ puts "start"
87
+ @date_time.in_time_zone("US/Eastern")
88
+ puts "done"
89
+ end
90
+ end
@@ -0,0 +1,15 @@
1
+ require 'tzinfo'
2
+
3
+
4
+ class Subject
5
+ def initialize(out=STDOUT)
6
+ @event = RiCal.Event do |e|
7
+ e.dtstart = "TZID=America/New_York:19970929T090000"
8
+ e.rrule = "FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-2"
9
+ end
10
+ end
11
+
12
+ def run
13
+ @event.occurrences(:count => 7)
14
+ end
15
+ end