gandirb 1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. data/CHANGELOG +1 -0
  2. data/LICENSE +19 -0
  3. data/README +35 -0
  4. data/Rakefile +32 -0
  5. data/gandirb.gemspec +34 -0
  6. data/lib/gandi/base.rb +121 -0
  7. data/lib/gandi/domain.rb +134 -0
  8. data/lib/gandi/domain_modules/contact.rb +36 -0
  9. data/lib/gandi/domain_modules/host.rb +29 -0
  10. data/lib/gandi/domain_modules/mail.rb +80 -0
  11. data/lib/gandi/domain_modules/name_servers.rb +28 -0
  12. data/lib/gandi/domain_modules/operations.rb +30 -0
  13. data/lib/gandi/domain_modules/redirection.rb +25 -0
  14. data/lib/gandi.rb +9 -0
  15. data/rdoc/classes/Gandi/Base.html +397 -0
  16. data/rdoc/classes/Gandi/DataError.html +111 -0
  17. data/rdoc/classes/Gandi/Domain.html +623 -0
  18. data/rdoc/classes/Gandi/DomainModules/Contact.html +246 -0
  19. data/rdoc/classes/Gandi/DomainModules/Host.html +227 -0
  20. data/rdoc/classes/Gandi/DomainModules/NameServers.html +226 -0
  21. data/rdoc/classes/Gandi/DomainModules/Operations.html +229 -0
  22. data/rdoc/classes/Gandi/DomainModules/Redirection.html +215 -0
  23. data/rdoc/classes/Gandi/DomainModules.html +136 -0
  24. data/rdoc/classes/Gandi/ServerError.html +111 -0
  25. data/rdoc/classes/Gandi.html +153 -0
  26. data/rdoc/created.rid +1 -0
  27. data/rdoc/files/README.html +162 -0
  28. data/rdoc/files/lib/gandi/base_rb.html +109 -0
  29. data/rdoc/files/lib/gandi/domain_modules/contact_rb.html +101 -0
  30. data/rdoc/files/lib/gandi/domain_modules/host_rb.html +101 -0
  31. data/rdoc/files/lib/gandi/domain_modules/name_servers_rb.html +101 -0
  32. data/rdoc/files/lib/gandi/domain_modules/operations_rb.html +101 -0
  33. data/rdoc/files/lib/gandi/domain_modules/redirection_rb.html +101 -0
  34. data/rdoc/files/lib/gandi/domain_rb.html +101 -0
  35. data/rdoc/files/lib/gandi_rb.html +101 -0
  36. data/rdoc/fr_class_index.html +38 -0
  37. data/rdoc/fr_file_index.html +36 -0
  38. data/rdoc/fr_method_index.html +83 -0
  39. data/rdoc/index.html +24 -0
  40. data/rdoc/rdoc-style.css +208 -0
  41. data/test/gandi/base_test.rb +188 -0
  42. data/test/gandi/domain_test.rb +302 -0
  43. data/test/gandi_test.rb +9 -0
  44. data/test/test_helper.rb +9 -0
  45. metadata +124 -0
@@ -0,0 +1,226 @@
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>Module: Gandi::DomainModules::NameServers</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>Module</strong></td>
53
+ <td class="class-name-in-header">Gandi::DomainModules::NameServers</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../../files/lib/gandi/domain_modules/name_servers_rb.html">
59
+ lib/gandi/domain_modules/name_servers.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ </table>
66
+ </div>
67
+ <!-- banner header -->
68
+
69
+ <div id="bodyContent">
70
+
71
+
72
+
73
+ <div id="contextContent">
74
+
75
+
76
+
77
+ </div>
78
+
79
+ <div id="method-list">
80
+ <h3 class="section-bar">Methods</h3>
81
+
82
+ <div class="name-list">
83
+ <a href="#M000026">domain_ns_add</a>&nbsp;&nbsp;
84
+ <a href="#M000027">domain_ns_del</a>&nbsp;&nbsp;
85
+ <a href="#M000025">domain_ns_list</a>&nbsp;&nbsp;
86
+ <a href="#M000028">domain_ns_set</a>&nbsp;&nbsp;
87
+ </div>
88
+ </div>
89
+
90
+ </div>
91
+
92
+
93
+ <!-- if includes -->
94
+
95
+ <div id="section">
96
+
97
+
98
+
99
+
100
+
101
+
102
+
103
+
104
+ <!-- if method_list -->
105
+ <div id="methods">
106
+ <h3 class="section-bar">Public Instance methods</h3>
107
+
108
+ <div id="method-M000026" class="method-detail">
109
+ <a name="M000026"></a>
110
+
111
+ <div class="method-heading">
112
+ <a href="#M000026" class="method-signature">
113
+ <span class="method-name">domain_ns_add</span><span class="method-args">(domain, ns_list)</span>
114
+ </a>
115
+ </div>
116
+
117
+ <div class="method-description">
118
+ <p>
119
+ Add the specified name servers to the name servers list of a domain Return
120
+ the operation attributed ID
121
+ </p>
122
+ <p><a class="source-toggle" href="#"
123
+ onclick="toggleCode('M000026-source');return false;">[Source]</a></p>
124
+ <div class="method-source-code" id="M000026-source">
125
+ <pre>
126
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/name_servers.rb, line 11</span>
127
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_ns_add</span>(<span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
128
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_ns_add'</span>, <span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
129
+ <span class="ruby-keyword kw">end</span>
130
+ </pre>
131
+ </div>
132
+ </div>
133
+ </div>
134
+
135
+ <div id="method-M000027" class="method-detail">
136
+ <a name="M000027"></a>
137
+
138
+ <div class="method-heading">
139
+ <a href="#M000027" class="method-signature">
140
+ <span class="method-name">domain_ns_del</span><span class="method-args">(domain, ns_list)</span>
141
+ </a>
142
+ </div>
143
+
144
+ <div class="method-description">
145
+ <p>
146
+ Remove the specified name servers from the name servers list of a domain
147
+ Return the operation attributed ID
148
+ </p>
149
+ <p><a class="source-toggle" href="#"
150
+ onclick="toggleCode('M000027-source');return false;">[Source]</a></p>
151
+ <div class="method-source-code" id="M000027-source">
152
+ <pre>
153
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/name_servers.rb, line 17</span>
154
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_ns_del</span>(<span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
155
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_ns_del'</span>, <span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
156
+ <span class="ruby-keyword kw">end</span>
157
+ </pre>
158
+ </div>
159
+ </div>
160
+ </div>
161
+
162
+ <div id="method-M000025" class="method-detail">
163
+ <a name="M000025"></a>
164
+
165
+ <div class="method-heading">
166
+ <a href="#M000025" class="method-signature">
167
+ <span class="method-name">domain_ns_list</span><span class="method-args">(domain)</span>
168
+ </a>
169
+ </div>
170
+
171
+ <div class="method-description">
172
+ <p>
173
+ Retrieve an array of name servers for a domain
174
+ </p>
175
+ <p><a class="source-toggle" href="#"
176
+ onclick="toggleCode('M000025-source');return false;">[Source]</a></p>
177
+ <div class="method-source-code" id="M000025-source">
178
+ <pre>
179
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/name_servers.rb, line 5</span>
180
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_ns_list</span>(<span class="ruby-identifier">domain</span>)
181
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_ns_list'</span>, <span class="ruby-identifier">domain</span>)
182
+ <span class="ruby-keyword kw">end</span>
183
+ </pre>
184
+ </div>
185
+ </div>
186
+ </div>
187
+
188
+ <div id="method-M000028" class="method-detail">
189
+ <a name="M000028"></a>
190
+
191
+ <div class="method-heading">
192
+ <a href="#M000028" class="method-signature">
193
+ <span class="method-name">domain_ns_set</span><span class="method-args">(domain, ns_list)</span>
194
+ </a>
195
+ </div>
196
+
197
+ <div class="method-description">
198
+ <p>
199
+ Set a domain name servers list Return the operation attributed ID
200
+ </p>
201
+ <p><a class="source-toggle" href="#"
202
+ onclick="toggleCode('M000028-source');return false;">[Source]</a></p>
203
+ <div class="method-source-code" id="M000028-source">
204
+ <pre>
205
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/name_servers.rb, line 23</span>
206
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_ns_set</span>(<span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
207
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_ns_set'</span>, <span class="ruby-identifier">domain</span>, <span class="ruby-identifier">ns_list</span>)
208
+ <span class="ruby-keyword kw">end</span>
209
+ </pre>
210
+ </div>
211
+ </div>
212
+ </div>
213
+
214
+
215
+ </div>
216
+
217
+
218
+ </div>
219
+
220
+
221
+ <div id="validator-badges">
222
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
223
+ </div>
224
+
225
+ </body>
226
+ </html>
@@ -0,0 +1,229 @@
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>Module: Gandi::DomainModules::Operations</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>Module</strong></td>
53
+ <td class="class-name-in-header">Gandi::DomainModules::Operations</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../../files/lib/gandi/domain_modules/operations_rb.html">
59
+ lib/gandi/domain_modules/operations.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ </table>
66
+ </div>
67
+ <!-- banner header -->
68
+
69
+ <div id="bodyContent">
70
+
71
+
72
+
73
+ <div id="contextContent">
74
+
75
+
76
+
77
+ </div>
78
+
79
+ <div id="method-list">
80
+ <h3 class="section-bar">Methods</h3>
81
+
82
+ <div class="name-list">
83
+ <a href="#M000021">operation_cancel</a>&nbsp;&nbsp;
84
+ <a href="#M000019">operation_details</a>&nbsp;&nbsp;
85
+ <a href="#M000018">operation_list</a>&nbsp;&nbsp;
86
+ <a href="#M000020">operation_relaunch</a>&nbsp;&nbsp;
87
+ </div>
88
+ </div>
89
+
90
+ </div>
91
+
92
+
93
+ <!-- if includes -->
94
+
95
+ <div id="section">
96
+
97
+
98
+
99
+
100
+
101
+
102
+
103
+
104
+ <!-- if method_list -->
105
+ <div id="methods">
106
+ <h3 class="section-bar">Public Instance methods</h3>
107
+
108
+ <div id="method-M000021" class="method-detail">
109
+ <a name="M000021"></a>
110
+
111
+ <div class="method-heading">
112
+ <a href="#M000021" class="method-signature">
113
+ <span class="method-name">operation_cancel</span><span class="method-args">(opid)</span>
114
+ </a>
115
+ </div>
116
+
117
+ <div class="method-description">
118
+ <p>
119
+ Cancel an operation
120
+ </p>
121
+ <p><a class="source-toggle" href="#"
122
+ onclick="toggleCode('M000021-source');return false;">[Source]</a></p>
123
+ <div class="method-source-code" id="M000021-source">
124
+ <pre>
125
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/operations.rb, line 25</span>
126
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">operation_cancel</span>(<span class="ruby-identifier">opid</span>)
127
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'operation_cancel'</span>, <span class="ruby-identifier">opid</span>)
128
+ <span class="ruby-keyword kw">end</span>
129
+ </pre>
130
+ </div>
131
+ </div>
132
+ </div>
133
+
134
+ <div id="method-M000019" class="method-detail">
135
+ <a name="M000019"></a>
136
+
137
+ <div class="method-heading">
138
+ <a href="#M000019" class="method-signature">
139
+ <span class="method-name">operation_details</span><span class="method-args">(opid)</span>
140
+ </a>
141
+ </div>
142
+
143
+ <div class="method-description">
144
+ <p>
145
+ Retrieve an operation details
146
+ </p>
147
+ <p><a class="source-toggle" href="#"
148
+ onclick="toggleCode('M000019-source');return false;">[Source]</a></p>
149
+ <div class="method-source-code" id="M000019-source">
150
+ <pre>
151
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/operations.rb, line 14</span>
152
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">operation_details</span>(<span class="ruby-identifier">opid</span>)
153
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'operation_details'</span>, <span class="ruby-identifier">opid</span>)
154
+ <span class="ruby-keyword kw">end</span>
155
+ </pre>
156
+ </div>
157
+ </div>
158
+ </div>
159
+
160
+ <div id="method-M000018" class="method-detail">
161
+ <a name="M000018"></a>
162
+
163
+ <div class="method-heading">
164
+ <a href="#M000018" class="method-signature">
165
+ <span class="method-name">operation_list</span><span class="method-args">(filter = {})</span>
166
+ </a>
167
+ </div>
168
+
169
+ <div class="method-description">
170
+ <p>
171
+ Retrieves an array of the last 300 operation IDs matching the optional
172
+ criterias
173
+ </p>
174
+ <p><a class="source-toggle" href="#"
175
+ onclick="toggleCode('M000018-source');return false;">[Source]</a></p>
176
+ <div class="method-source-code" id="M000018-source">
177
+ <pre>
178
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/operations.rb, line 5</span>
179
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">operation_list</span>(<span class="ruby-identifier">filter</span> = {})
180
+ <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">filter</span>.<span class="ruby-identifier">empty?</span>
181
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'operation_list'</span>, <span class="ruby-identifier">filter</span>)
182
+ <span class="ruby-keyword kw">else</span>
183
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'operation_list'</span>)
184
+ <span class="ruby-keyword kw">end</span>
185
+ <span class="ruby-keyword kw">end</span>
186
+ </pre>
187
+ </div>
188
+ </div>
189
+ </div>
190
+
191
+ <div id="method-M000020" class="method-detail">
192
+ <a name="M000020"></a>
193
+
194
+ <div class="method-heading">
195
+ <a href="#M000020" class="method-signature">
196
+ <span class="method-name">operation_relaunch</span><span class="method-args">(opid, param)</span>
197
+ </a>
198
+ </div>
199
+
200
+ <div class="method-description">
201
+ <p>
202
+ Relaunch an operation, modifying the given parameters TODO: check param
203
+ </p>
204
+ <p><a class="source-toggle" href="#"
205
+ onclick="toggleCode('M000020-source');return false;">[Source]</a></p>
206
+ <div class="method-source-code" id="M000020-source">
207
+ <pre>
208
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/operations.rb, line 20</span>
209
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">operation_relaunch</span>(<span class="ruby-identifier">opid</span>, <span class="ruby-identifier">param</span>)
210
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'operation_relaunch'</span>, <span class="ruby-identifier">opid</span>, <span class="ruby-identifier">param</span>)
211
+ <span class="ruby-keyword kw">end</span>
212
+ </pre>
213
+ </div>
214
+ </div>
215
+ </div>
216
+
217
+
218
+ </div>
219
+
220
+
221
+ </div>
222
+
223
+
224
+ <div id="validator-badges">
225
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
226
+ </div>
227
+
228
+ </body>
229
+ </html>
@@ -0,0 +1,215 @@
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>Module: Gandi::DomainModules::Redirection</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>Module</strong></td>
53
+ <td class="class-name-in-header">Gandi::DomainModules::Redirection</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../../files/lib/gandi/domain_modules/redirection_rb.html">
59
+ lib/gandi/domain_modules/redirection.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ </table>
66
+ </div>
67
+ <!-- banner header -->
68
+
69
+ <div id="bodyContent">
70
+
71
+
72
+
73
+ <div id="contextContent">
74
+
75
+
76
+
77
+ </div>
78
+
79
+ <div id="method-list">
80
+ <h3 class="section-bar">Methods</h3>
81
+
82
+ <div class="name-list">
83
+ <a href="#M000023">domain_web_redir_add</a>&nbsp;&nbsp;
84
+ <a href="#M000024">domain_web_redir_del</a>&nbsp;&nbsp;
85
+ <a href="#M000022">domain_web_redir_list</a>&nbsp;&nbsp;
86
+ </div>
87
+ </div>
88
+
89
+ </div>
90
+
91
+
92
+ <!-- if includes -->
93
+
94
+ <div id="section">
95
+
96
+
97
+ <div id="constants-list">
98
+ <h3 class="section-bar">Constants</h3>
99
+
100
+ <div class="name-list">
101
+ <table summary="Constants">
102
+ <tr class="top-aligned-row context-row">
103
+ <td class="context-item-name">DOMAIN_WEB_REDIR_REDIRECTION_TYPES</td>
104
+ <td>=</td>
105
+ <td class="context-item-value">['http302', 'http301', 'cloak']</td>
106
+ </tr>
107
+ </table>
108
+ </div>
109
+ </div>
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-M000023" class="method-detail">
121
+ <a name="M000023"></a>
122
+
123
+ <div class="method-heading">
124
+ <a href="#M000023" class="method-signature">
125
+ <span class="method-name">domain_web_redir_add</span><span class="method-args">(domain, fqdn, destination_url, type)</span>
126
+ </a>
127
+ </div>
128
+
129
+ <div class="method-description">
130
+ <p>
131
+ Add a web redirection to a domain. All HTTP requests to <a
132
+ href="http://fqdn">fqdn</a>/ will be redirected to
133
+ &#8216;destination_url&#8217; with a HTTP redirection &#8216;type&#8217;
134
+ Return the operation attributed ID
135
+ </p>
136
+ <p><a class="source-toggle" href="#"
137
+ onclick="toggleCode('M000023-source');return false;">[Source]</a></p>
138
+ <div class="method-source-code" id="M000023-source">
139
+ <pre>
140
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/redirection.rb, line 13</span>
141
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_web_redir_add</span>(<span class="ruby-identifier">domain</span>, <span class="ruby-identifier">fqdn</span>, <span class="ruby-identifier">destination_url</span>, <span class="ruby-identifier">type</span>)
142
+ <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">&quot;Redirection type is invalid&quot;</span>) <span class="ruby-keyword kw">unless</span> <span class="ruby-constant">DOMAIN_WEB_REDIR_REDIRECTION_TYPES</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">type</span>)
143
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_web_redir_add'</span>, <span class="ruby-identifier">domain</span>, <span class="ruby-identifier">fqdn</span>, <span class="ruby-identifier">destination_url</span>, <span class="ruby-identifier">type</span>)
144
+ <span class="ruby-keyword kw">end</span>
145
+ </pre>
146
+ </div>
147
+ </div>
148
+ </div>
149
+
150
+ <div id="method-M000024" class="method-detail">
151
+ <a name="M000024"></a>
152
+
153
+ <div class="method-heading">
154
+ <a href="#M000024" class="method-signature">
155
+ <span class="method-name">domain_web_redir_del</span><span class="method-args">(fqdn)</span>
156
+ </a>
157
+ </div>
158
+
159
+ <div class="method-description">
160
+ <p>
161
+ Delete the web redirection of the fully qualified domain name fqdn Return
162
+ the operation attributed ID
163
+ </p>
164
+ <p><a class="source-toggle" href="#"
165
+ onclick="toggleCode('M000024-source');return false;">[Source]</a></p>
166
+ <div class="method-source-code" id="M000024-source">
167
+ <pre>
168
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/redirection.rb, line 20</span>
169
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_web_redir_del</span>(<span class="ruby-identifier">fqdn</span>)
170
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_web_redir_del'</span>, <span class="ruby-identifier">fqdn</span>)
171
+ <span class="ruby-keyword kw">end</span>
172
+ </pre>
173
+ </div>
174
+ </div>
175
+ </div>
176
+
177
+ <div id="method-M000022" class="method-detail">
178
+ <a name="M000022"></a>
179
+
180
+ <div class="method-heading">
181
+ <a href="#M000022" class="method-signature">
182
+ <span class="method-name">domain_web_redir_list</span><span class="method-args">(domain)</span>
183
+ </a>
184
+ </div>
185
+
186
+ <div class="method-description">
187
+ <p>
188
+ Retrieve an array of web redirections for a domain
189
+ </p>
190
+ <p><a class="source-toggle" href="#"
191
+ onclick="toggleCode('M000022-source');return false;">[Source]</a></p>
192
+ <div class="method-source-code" id="M000022-source">
193
+ <pre>
194
+ <span class="ruby-comment cmt"># File lib/gandi/domain_modules/redirection.rb, line 7</span>
195
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">domain_web_redir_list</span>(<span class="ruby-identifier">domain</span>)
196
+ <span class="ruby-identifier">call</span>(<span class="ruby-value str">'domain_web_redir_list'</span>, <span class="ruby-identifier">domain</span>)
197
+ <span class="ruby-keyword kw">end</span>
198
+ </pre>
199
+ </div>
200
+ </div>
201
+ </div>
202
+
203
+
204
+ </div>
205
+
206
+
207
+ </div>
208
+
209
+
210
+ <div id="validator-badges">
211
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
212
+ </div>
213
+
214
+ </body>
215
+ </html>