icalendar 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +26 -3
- data/docs/api/classes/Array.html +155 -0
- data/docs/api/classes/Bignum.html +148 -0
- data/docs/api/classes/Date.html +172 -0
- data/docs/api/classes/DateTime.html +200 -0
- data/docs/api/classes/Fixnum.html +148 -0
- data/docs/api/classes/Float.html +148 -0
- data/docs/api/classes/HashAttrs.html +212 -0
- data/docs/api/classes/Icalendar/Alarm.html +228 -0
- data/docs/api/classes/Icalendar/Base.html +179 -0
- data/docs/api/classes/Icalendar/Calendar.html +504 -0
- data/docs/api/classes/Icalendar/Component.html +853 -0
- data/docs/api/classes/Icalendar/DateProp.html +187 -0
- data/docs/api/classes/Icalendar/DateProp/ClassMethods.html +195 -0
- data/docs/api/classes/Icalendar/Daylight.html +156 -0
- data/docs/api/classes/Icalendar/Event.html +671 -0
- data/docs/api/classes/Icalendar/Freebusy.html +266 -0
- data/docs/api/classes/Icalendar/Geo.html +211 -0
- data/docs/api/classes/Icalendar/InvalidPropertyValue.html +117 -0
- data/docs/api/classes/Icalendar/Journal.html +443 -0
- data/docs/api/classes/Icalendar/Parameter.html +166 -0
- data/docs/api/classes/Icalendar/Parser.html +352 -0
- data/docs/api/classes/Icalendar/RRule.html +428 -0
- data/docs/api/classes/Icalendar/RRule/Weekday.html +199 -0
- data/docs/api/classes/Icalendar/Standard.html +156 -0
- data/docs/api/classes/Icalendar/Timezone.html +450 -0
- data/docs/api/classes/Icalendar/Todo.html +480 -0
- data/docs/api/classes/Icalendar/TzidSupport.html +118 -0
- data/docs/api/classes/Icalendar/UnknownComponentClass.html +117 -0
- data/docs/api/classes/Icalendar/UnknownPropertyMethod.html +117 -0
- data/docs/api/classes/Object.html +272 -0
- data/docs/api/classes/String.html +148 -0
- data/docs/api/classes/TZInfo.html +119 -0
- data/docs/api/classes/TZInfo/Timezone.html +153 -0
- data/docs/api/classes/TZInfo/TimezonePeriod.html +200 -0
- data/docs/api/classes/TZInfo/TimezoneTransitionInfo.html +229 -0
- data/docs/api/classes/Time.html +180 -0
- data/docs/api/classes/URI.html +111 -0
- data/docs/api/classes/URI/Generic.html +148 -0
- data/docs/api/created.rid +1 -0
- data/docs/api/files/COPYING.html +163 -0
- data/docs/api/files/GPL.html +531 -0
- data/docs/api/files/README.html +401 -0
- data/docs/api/files/lib/hash_attrs_rb.html +107 -0
- data/docs/api/files/lib/icalendar/base_rb.html +108 -0
- data/docs/api/files/lib/icalendar/calendar_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/alarm_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/event_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/freebusy_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/journal_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/timezone_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component/todo_rb.html +101 -0
- data/docs/api/files/lib/icalendar/component_rb.html +108 -0
- data/docs/api/files/lib/icalendar/conversions_rb.html +109 -0
- data/docs/api/files/lib/icalendar/helpers_rb.html +101 -0
- data/docs/api/files/lib/icalendar/parameter_rb.html +101 -0
- data/docs/api/files/lib/icalendar/parser_rb.html +110 -0
- data/docs/api/files/lib/icalendar/rrule_rb.html +110 -0
- data/docs/api/files/lib/icalendar/tzinfo_rb.html +101 -0
- data/docs/api/files/lib/icalendar_rb.html +121 -0
- data/docs/api/files/lib/meta_rb.html +107 -0
- data/docs/api/fr_class_index.html +64 -0
- data/docs/api/fr_file_index.html +47 -0
- data/docs/api/fr_method_index.html +123 -0
- data/docs/api/index.html +24 -0
- data/docs/api/rdoc-style.css +208 -0
- data/lib/icalendar.rb +1 -0
- data/lib/icalendar/component.rb +3 -3
- data/lib/icalendar/component/event.rb +1 -1
- data/lib/icalendar/component/freebusy.rb +1 -0
- data/lib/icalendar/conversions.rb +6 -0
- data/lib/icalendar/conversions.rb.orig +144 -0
- data/lib/icalendar/parser.rb +0 -94
- data/lib/icalendar/rrule.rb +133 -0
- data/test/component/timezone_test.rb +1 -1
- data/test/component_test.rb +10 -0
- data/test/conversions_test.rb +4 -4
- data/test/coverage/index.html +272 -0
- data/test/coverage/lib-hash_attrs_rb.html +235 -0
- data/test/coverage/lib-icalendar-base_rb.html +249 -0
- data/test/coverage/lib-icalendar-calendar_rb.html +324 -0
- data/test/coverage/lib-icalendar-component-alarm_rb.html +250 -0
- data/test/coverage/lib-icalendar-component-event_rb.html +353 -0
- data/test/coverage/lib-icalendar-component-freebusy_rb.html +245 -0
- data/test/coverage/lib-icalendar-component-journal_rb.html +278 -0
- data/test/coverage/lib-icalendar-component-timezone_rb.html +326 -0
- data/test/coverage/lib-icalendar-component-todo_rb.html +277 -0
- data/test/coverage/lib-icalendar-component_rb.html +733 -0
- data/test/coverage/lib-icalendar-conversions_rb.html +358 -0
- data/test/coverage/lib-icalendar-parser_rb.html +671 -0
- data/test/coverage/lib-icalendar-rrule_rb.html +357 -0
- data/test/coverage/lib-icalendar_rb.html +243 -0
- data/test/coverage/lib-meta_rb.html +234 -0
- data/test/fixtures/folding.ics +2 -2
- metadata +113 -36
- data/docs/api/STUB +0 -0
data/Rakefile
CHANGED
@@ -5,7 +5,8 @@ require 'rake/rdoctask'
|
|
5
5
|
require 'rake/clean'
|
6
6
|
require 'rake/contrib/sshpublisher'
|
7
7
|
|
8
|
-
|
8
|
+
PKG_NAME = "icalendar"
|
9
|
+
PKG_VERSION = "1.1.1"
|
9
10
|
|
10
11
|
$VERBOSE = nil
|
11
12
|
TEST_CHANGES_SINCE = Time.now - 600 # Recent tests = changed in last 10 minutes
|
@@ -21,7 +22,7 @@ Rake::TestTask.new(:test) { |t|
|
|
21
22
|
}
|
22
23
|
|
23
24
|
# rcov code coverage
|
24
|
-
rcov_path = '/usr/
|
25
|
+
rcov_path = '/usr/bin/rcov'
|
25
26
|
rcov_test_output = "./test/coverage"
|
26
27
|
rcov_exclude = "interactive.rb,read_write.rb,fixtures"
|
27
28
|
|
@@ -55,7 +56,8 @@ Rake::RDocTask.new(:doc) { |rdoc|
|
|
55
56
|
rdoc.options << "--accessor=ical_component,ical_property,ical_multi_property"
|
56
57
|
}
|
57
58
|
|
58
|
-
|
59
|
+
require 'rubygems'
|
60
|
+
require 'rubygems/gem_runner'
|
59
61
|
require 'rake/gempackagetask'
|
60
62
|
|
61
63
|
spec = Gem::Specification.new do |s|
|
@@ -84,6 +86,27 @@ Rake::GemPackageTask.new(spec) do |pkg|
|
|
84
86
|
pkg.need_zip = true
|
85
87
|
end
|
86
88
|
|
89
|
+
desc "Upload Docs to RubyForge"
|
90
|
+
task :publish_docs => [:doc] do
|
91
|
+
publisher = Rake::SshDirPublisher.new(
|
92
|
+
"sdague@rubyforge.org",
|
93
|
+
"/var/www/gforge-projects/icalendar",
|
94
|
+
"docs/api"
|
95
|
+
)
|
96
|
+
publisher.upload
|
97
|
+
end
|
98
|
+
|
99
|
+
desc "Publish the release files to RubyForge."
|
100
|
+
task :release => [ :package, :publish_docs ] do
|
101
|
+
require 'rubyforge'
|
102
|
+
packages = %w( gem tgz zip ).collect{ |ext| "pkg/#{PKG_NAME}-#{PKG_VERSION}.#{ext}" }
|
103
|
+
rubyforge = RubyForge.new
|
104
|
+
rubyforge.configure
|
105
|
+
rubyforge.scrape_config
|
106
|
+
rubyforge.scrape_project(PKG_NAME)
|
107
|
+
rubyforge.add_release(540, PKG_NAME, "v#{PKG_VERSION}", *packages)
|
108
|
+
end
|
109
|
+
|
87
110
|
desc 'Install the gem globally (requires sudo)'
|
88
111
|
task :install => :package do |t|
|
89
112
|
`sudo gem install pkg/icalendar-#{PKG_VERSION}.gem`
|
@@ -0,0 +1,155 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: Array</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">Array</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/icalendar/conversions_rb.html">
|
59
|
+
lib/icalendar/conversions.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
<a href="Object.html">
|
69
|
+
Object
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
<div id="description">
|
84
|
+
<p>
|
85
|
+
From the spec: "Values in a list of values MUST be separated by a
|
86
|
+
COMMA character (US-ASCII decimal 44)."
|
87
|
+
</p>
|
88
|
+
|
89
|
+
</div>
|
90
|
+
|
91
|
+
|
92
|
+
</div>
|
93
|
+
|
94
|
+
<div id="method-list">
|
95
|
+
<h3 class="section-bar">Methods</h3>
|
96
|
+
|
97
|
+
<div class="name-list">
|
98
|
+
<a href="#M000007">to_ical</a>
|
99
|
+
</div>
|
100
|
+
</div>
|
101
|
+
|
102
|
+
</div>
|
103
|
+
|
104
|
+
|
105
|
+
<!-- if includes -->
|
106
|
+
|
107
|
+
<div id="section">
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
<!-- if method_list -->
|
117
|
+
<div id="methods">
|
118
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
119
|
+
|
120
|
+
<div id="method-M000007" class="method-detail">
|
121
|
+
<a name="M000007"></a>
|
122
|
+
|
123
|
+
<div class="method-heading">
|
124
|
+
<a href="#M000007" class="method-signature">
|
125
|
+
<span class="method-name">to_ical</span><span class="method-args">()</span>
|
126
|
+
</a>
|
127
|
+
</div>
|
128
|
+
|
129
|
+
<div class="method-description">
|
130
|
+
<p><a class="source-toggle" href="#"
|
131
|
+
onclick="toggleCode('M000007-source');return false;">[Source]</a></p>
|
132
|
+
<div class="method-source-code" id="M000007-source">
|
133
|
+
<pre>
|
134
|
+
<span class="ruby-comment cmt"># File lib/icalendar/conversions.rb, line 54</span>
|
135
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_ical</span>
|
136
|
+
<span class="ruby-identifier">map</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">elem</span><span class="ruby-operator">|</span> <span class="ruby-identifier">elem</span>.<span class="ruby-identifier">to_ical</span>}.<span class="ruby-identifier">join</span> <span class="ruby-value str">','</span>
|
137
|
+
<span class="ruby-keyword kw">end</span>
|
138
|
+
</pre>
|
139
|
+
</div>
|
140
|
+
</div>
|
141
|
+
</div>
|
142
|
+
|
143
|
+
|
144
|
+
</div>
|
145
|
+
|
146
|
+
|
147
|
+
</div>
|
148
|
+
|
149
|
+
|
150
|
+
<div id="validator-badges">
|
151
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
152
|
+
</div>
|
153
|
+
|
154
|
+
</body>
|
155
|
+
</html>
|
@@ -0,0 +1,148 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: Bignum</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">Bignum</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/icalendar/conversions_rb.html">
|
59
|
+
lib/icalendar/conversions.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
<a href="Object.html">
|
69
|
+
Object
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
</div>
|
86
|
+
|
87
|
+
<div id="method-list">
|
88
|
+
<h3 class="section-bar">Methods</h3>
|
89
|
+
|
90
|
+
<div class="name-list">
|
91
|
+
<a href="#M000006">to_ical</a>
|
92
|
+
</div>
|
93
|
+
</div>
|
94
|
+
|
95
|
+
</div>
|
96
|
+
|
97
|
+
|
98
|
+
<!-- if includes -->
|
99
|
+
|
100
|
+
<div id="section">
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
<!-- if method_list -->
|
110
|
+
<div id="methods">
|
111
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
112
|
+
|
113
|
+
<div id="method-M000006" class="method-detail">
|
114
|
+
<a name="M000006"></a>
|
115
|
+
|
116
|
+
<div class="method-heading">
|
117
|
+
<a href="#M000006" class="method-signature">
|
118
|
+
<span class="method-name">to_ical</span><span class="method-args">()</span>
|
119
|
+
</a>
|
120
|
+
</div>
|
121
|
+
|
122
|
+
<div class="method-description">
|
123
|
+
<p><a class="source-toggle" href="#"
|
124
|
+
onclick="toggleCode('M000006-source');return false;">[Source]</a></p>
|
125
|
+
<div class="method-source-code" id="M000006-source">
|
126
|
+
<pre>
|
127
|
+
<span class="ruby-comment cmt"># File lib/icalendar/conversions.rb, line 40</span>
|
128
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_ical</span>
|
129
|
+
<span class="ruby-node">"#{self}"</span>
|
130
|
+
<span class="ruby-keyword kw">end</span>
|
131
|
+
</pre>
|
132
|
+
</div>
|
133
|
+
</div>
|
134
|
+
</div>
|
135
|
+
|
136
|
+
|
137
|
+
</div>
|
138
|
+
|
139
|
+
|
140
|
+
</div>
|
141
|
+
|
142
|
+
|
143
|
+
<div id="validator-badges">
|
144
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
145
|
+
</div>
|
146
|
+
|
147
|
+
</body>
|
148
|
+
</html>
|
@@ -0,0 +1,172 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: Date</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">Date</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/icalendar/conversions_rb.html">
|
59
|
+
lib/icalendar/conversions.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
<a href="Object.html">
|
69
|
+
Object
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
</div>
|
86
|
+
|
87
|
+
<div id="method-list">
|
88
|
+
<h3 class="section-bar">Methods</h3>
|
89
|
+
|
90
|
+
<div class="name-list">
|
91
|
+
<a href="#M000009">to_ical</a>
|
92
|
+
</div>
|
93
|
+
</div>
|
94
|
+
|
95
|
+
</div>
|
96
|
+
|
97
|
+
|
98
|
+
<!-- if includes -->
|
99
|
+
|
100
|
+
<div id="section">
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
|
106
|
+
<div id="attribute-list">
|
107
|
+
<h3 class="section-bar">Attributes</h3>
|
108
|
+
|
109
|
+
<div class="name-list">
|
110
|
+
<table>
|
111
|
+
<tr class="top-aligned-row context-row">
|
112
|
+
<td class="context-item-name">ical_params</td>
|
113
|
+
<td class="context-item-value"> [RW] </td>
|
114
|
+
<td class="context-item-desc"></td>
|
115
|
+
</tr>
|
116
|
+
</table>
|
117
|
+
</div>
|
118
|
+
</div>
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
<!-- if method_list -->
|
123
|
+
<div id="methods">
|
124
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
125
|
+
|
126
|
+
<div id="method-M000009" class="method-detail">
|
127
|
+
<a name="M000009"></a>
|
128
|
+
|
129
|
+
<div class="method-heading">
|
130
|
+
<a href="#M000009" class="method-signature">
|
131
|
+
<span class="method-name">to_ical</span><span class="method-args">(utc = false)</span>
|
132
|
+
</a>
|
133
|
+
</div>
|
134
|
+
|
135
|
+
<div class="method-description">
|
136
|
+
<p><a class="source-toggle" href="#"
|
137
|
+
onclick="toggleCode('M000009-source');return false;">[Source]</a></p>
|
138
|
+
<div class="method-source-code" id="M000009-source">
|
139
|
+
<pre>
|
140
|
+
<span class="ruby-comment cmt"># File lib/icalendar/conversions.rb, line 110</span>
|
141
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_ical</span>(<span class="ruby-identifier">utc</span> = <span class="ruby-keyword kw">false</span>)
|
142
|
+
<span class="ruby-identifier">s</span> = <span class="ruby-value str">""</span>
|
143
|
+
|
144
|
+
<span class="ruby-comment cmt"># 4 digit year</span>
|
145
|
+
<span class="ruby-identifier">s</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">year</span>.<span class="ruby-identifier">to_s</span>
|
146
|
+
|
147
|
+
<span class="ruby-comment cmt"># Double digit month</span>
|
148
|
+
<span class="ruby-identifier">s</span> <span class="ruby-operator"><<</span> <span class="ruby-value str">"0"</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">month</span> <span class="ruby-operator">></span> <span class="ruby-value">9</span>
|
149
|
+
<span class="ruby-identifier">s</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">month</span>.<span class="ruby-identifier">to_s</span>
|
150
|
+
|
151
|
+
<span class="ruby-comment cmt"># Double digit day</span>
|
152
|
+
<span class="ruby-identifier">s</span> <span class="ruby-operator"><<</span> <span class="ruby-value str">"0"</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">day</span> <span class="ruby-operator">></span> <span class="ruby-value">9</span>
|
153
|
+
<span class="ruby-identifier">s</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">day</span>.<span class="ruby-identifier">to_s</span>
|
154
|
+
<span class="ruby-keyword kw">end</span>
|
155
|
+
</pre>
|
156
|
+
</div>
|
157
|
+
</div>
|
158
|
+
</div>
|
159
|
+
|
160
|
+
|
161
|
+
</div>
|
162
|
+
|
163
|
+
|
164
|
+
</div>
|
165
|
+
|
166
|
+
|
167
|
+
<div id="validator-badges">
|
168
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
169
|
+
</div>
|
170
|
+
|
171
|
+
</body>
|
172
|
+
</html>
|