gandirb 1.0 → 1.1.1
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.
- data/CHANGELOG +14 -1
- data/Gemfile +3 -0
- data/README.rdoc +36 -0
- data/Rakefile +8 -17
- data/gandirb.gemspec +23 -24
- data/lib/gandi/base.rb +28 -28
- data/lib/gandi/domain.rb +7 -8
- data/lib/gandi/domain_modules/contact.rb +1 -1
- data/lib/gandi/domain_modules/operations.rb +1 -1
- data/lib/gandi/domain_modules/redirection.rb +2 -2
- data/lib/gandi/version.rb +3 -0
- data/lib/gandi.rb +3 -4
- data/test/gandi/domain_test.rb +7 -8
- metadata +98 -89
- data/README +0 -35
- data/rdoc/classes/Gandi/Base.html +0 -397
- data/rdoc/classes/Gandi/DataError.html +0 -111
- data/rdoc/classes/Gandi/Domain.html +0 -623
- data/rdoc/classes/Gandi/DomainModules/Contact.html +0 -246
- data/rdoc/classes/Gandi/DomainModules/Host.html +0 -227
- data/rdoc/classes/Gandi/DomainModules/NameServers.html +0 -226
- data/rdoc/classes/Gandi/DomainModules/Operations.html +0 -229
- data/rdoc/classes/Gandi/DomainModules/Redirection.html +0 -215
- data/rdoc/classes/Gandi/DomainModules.html +0 -136
- data/rdoc/classes/Gandi/ServerError.html +0 -111
- data/rdoc/classes/Gandi.html +0 -153
- data/rdoc/created.rid +0 -1
- data/rdoc/files/README.html +0 -162
- data/rdoc/files/lib/gandi/base_rb.html +0 -109
- data/rdoc/files/lib/gandi/domain_modules/contact_rb.html +0 -101
- data/rdoc/files/lib/gandi/domain_modules/host_rb.html +0 -101
- data/rdoc/files/lib/gandi/domain_modules/name_servers_rb.html +0 -101
- data/rdoc/files/lib/gandi/domain_modules/operations_rb.html +0 -101
- data/rdoc/files/lib/gandi/domain_modules/redirection_rb.html +0 -101
- data/rdoc/files/lib/gandi/domain_rb.html +0 -101
- data/rdoc/files/lib/gandi_rb.html +0 -101
- data/rdoc/fr_class_index.html +0 -38
- data/rdoc/fr_file_index.html +0 -36
- data/rdoc/fr_method_index.html +0 -83
- data/rdoc/index.html +0 -24
- data/rdoc/rdoc-style.css +0 -208
data/README
DELETED
@@ -1,35 +0,0 @@
|
|
1
|
-
= Gandirb - Ruby library for using Gandi XML-RPC API
|
2
|
-
|
3
|
-
This is a ruby library for using Gandi XML-RPC API.
|
4
|
-
It should only support the domain and mail API, but may be extensible enough to add hosting in the future.
|
5
|
-
|
6
|
-
== Howto
|
7
|
-
|
8
|
-
See http://wiki.gandi.net/fr/api-xml/docs/domain for the full documentation on the API.
|
9
|
-
Note the session_id doesn't have to be explicitly provided when calling a method.
|
10
|
-
|
11
|
-
It should also be noted that the ruby xml-rpc lib seems to have a bug with the ssl support, resulting in a timeout of 15 seconds.
|
12
|
-
After this time the current connection won't work and result in various exception.
|
13
|
-
This lib takes this issue into account and provides a workaround by restarting the connection. See the code comments for more details.
|
14
|
-
|
15
|
-
Quick example :
|
16
|
-
|
17
|
-
gandi_session = Gandi::Domain.login 'XXYYY-Gandi', 'mypasswd', Gandi::Domain::TEST_URL #omit the last param for real url
|
18
|
-
gandi_session.account_currency # => "EUR"
|
19
|
-
gandi_session.domain_available ["mycoolwebsite.com"] # => {"mycoolwebsite.com"=>true}
|
20
|
-
gandi_session.domain_available "mycoolwebsite.com" # => true #rubyfied syntax
|
21
|
-
gandi_session.domain_list # => ["mypersonalwebsite.com"]
|
22
|
-
|
23
|
-
Detailed RDoc documentation for each method is available using rake rdoc.
|
24
|
-
|
25
|
-
== TODO
|
26
|
-
|
27
|
-
* Tests
|
28
|
-
* Finish adding and cleaning up domain and mail methods
|
29
|
-
* Better handling of failures and server exceptions, and stricter params checking
|
30
|
-
* Gemification (with Jeweler)
|
31
|
-
|
32
|
-
== Copyright
|
33
|
-
|
34
|
-
Copyright (c) 2009 Pickabee. Released under the MIT licence, see LICENSE for details.
|
35
|
-
Some parts inspired by http://github.com/jerome/gandi/tree
|
@@ -1,397 +0,0 @@
|
|
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: Gandi::Base</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">Gandi::Base</td>
|
54
|
-
</tr>
|
55
|
-
<tr class="top-aligned-row">
|
56
|
-
<td><strong>In:</strong></td>
|
57
|
-
<td>
|
58
|
-
<a href="../../files/lib/gandi/base_rb.html">
|
59
|
-
lib/gandi/base.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
|
-
Object
|
69
|
-
</td>
|
70
|
-
</tr>
|
71
|
-
</table>
|
72
|
-
</div>
|
73
|
-
<!-- banner header -->
|
74
|
-
|
75
|
-
<div id="bodyContent">
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
<div id="contextContent">
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
</div>
|
84
|
-
|
85
|
-
<div id="method-list">
|
86
|
-
<h3 class="section-bar">Methods</h3>
|
87
|
-
|
88
|
-
<div class="name-list">
|
89
|
-
<a href="#M000055">account_balance</a>
|
90
|
-
<a href="#M000056">account_currency</a>
|
91
|
-
<a href="#M000051">call</a>
|
92
|
-
<a href="#M000052">login</a>
|
93
|
-
<a href="#M000057">login</a>
|
94
|
-
<a href="#M000050">new</a>
|
95
|
-
<a href="#M000054">password</a>
|
96
|
-
<a href="#M000053">su</a>
|
97
|
-
</div>
|
98
|
-
</div>
|
99
|
-
|
100
|
-
</div>
|
101
|
-
|
102
|
-
|
103
|
-
<!-- if includes -->
|
104
|
-
|
105
|
-
<div id="section">
|
106
|
-
|
107
|
-
|
108
|
-
<div id="constants-list">
|
109
|
-
<h3 class="section-bar">Constants</h3>
|
110
|
-
|
111
|
-
<div class="name-list">
|
112
|
-
<table summary="Constants">
|
113
|
-
<tr class="top-aligned-row context-row">
|
114
|
-
<td class="context-item-name">TIMEOUT_EXCEPTIONS</td>
|
115
|
-
<td>=</td>
|
116
|
-
<td class="context-item-value">[EOFError, Errno::EPIPE, OpenSSL::SSL::SSLError]</td>
|
117
|
-
</tr>
|
118
|
-
<tr class="top-aligned-row context-row">
|
119
|
-
<td class="context-item-name">URL</td>
|
120
|
-
<td>=</td>
|
121
|
-
<td class="context-item-value">"https://api.gandi.net/xmlrpc/"</td>
|
122
|
-
</tr>
|
123
|
-
<tr class="top-aligned-row context-row">
|
124
|
-
<td class="context-item-name">TEST_URL</td>
|
125
|
-
<td>=</td>
|
126
|
-
<td class="context-item-value">"https://api.ote.gandi.net/xmlrpc/"</td>
|
127
|
-
</tr>
|
128
|
-
</table>
|
129
|
-
</div>
|
130
|
-
</div>
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
<div id="attribute-list">
|
135
|
-
<h3 class="section-bar">Attributes</h3>
|
136
|
-
|
137
|
-
<div class="name-list">
|
138
|
-
<table>
|
139
|
-
<tr class="top-aligned-row context-row">
|
140
|
-
<td class="context-item-name">handler</td>
|
141
|
-
<td class="context-item-value"> [R] </td>
|
142
|
-
<td class="context-item-desc"></td>
|
143
|
-
</tr>
|
144
|
-
<tr class="top-aligned-row context-row">
|
145
|
-
<td class="context-item-name">session_id</td>
|
146
|
-
<td class="context-item-value"> [R] </td>
|
147
|
-
<td class="context-item-desc"></td>
|
148
|
-
</tr>
|
149
|
-
</table>
|
150
|
-
</div>
|
151
|
-
</div>
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
<!-- if method_list -->
|
156
|
-
<div id="methods">
|
157
|
-
<h3 class="section-bar">Public Class methods</h3>
|
158
|
-
|
159
|
-
<div id="method-M000057" class="method-detail">
|
160
|
-
<a name="M000057"></a>
|
161
|
-
|
162
|
-
<div class="method-heading">
|
163
|
-
<a href="#M000057" class="method-signature">
|
164
|
-
<span class="method-name">login</span><span class="method-args">(login, password, uri = nil)</span>
|
165
|
-
</a>
|
166
|
-
</div>
|
167
|
-
|
168
|
-
<div class="method-description">
|
169
|
-
<p><a class="source-toggle" href="#"
|
170
|
-
onclick="toggleCode('M000057-source');return false;">[Source]</a></p>
|
171
|
-
<div class="method-source-code" id="M000057-source">
|
172
|
-
<pre>
|
173
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 69</span>
|
174
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">login</span>(<span class="ruby-identifier">login</span>, <span class="ruby-identifier">password</span>, <span class="ruby-identifier">uri</span> = <span class="ruby-keyword kw">nil</span>)
|
175
|
-
<span class="ruby-identifier">client</span> = <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">login</span>, <span class="ruby-identifier">password</span>, <span class="ruby-identifier">uri</span>)
|
176
|
-
<span class="ruby-identifier">client</span>.<span class="ruby-identifier">login</span>
|
177
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">client</span>
|
178
|
-
<span class="ruby-keyword kw">end</span>
|
179
|
-
</pre>
|
180
|
-
</div>
|
181
|
-
</div>
|
182
|
-
</div>
|
183
|
-
|
184
|
-
<div id="method-M000050" class="method-detail">
|
185
|
-
<a name="M000050"></a>
|
186
|
-
|
187
|
-
<div class="method-heading">
|
188
|
-
<a href="#M000050" class="method-signature">
|
189
|
-
<span class="method-name">new</span><span class="method-args">(login, password, uri = nil)</span>
|
190
|
-
</a>
|
191
|
-
</div>
|
192
|
-
|
193
|
-
<div class="method-description">
|
194
|
-
<p><a class="source-toggle" href="#"
|
195
|
-
onclick="toggleCode('M000050-source');return false;">[Source]</a></p>
|
196
|
-
<div class="method-source-code" id="M000050-source">
|
197
|
-
<pre>
|
198
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 17</span>
|
199
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">login</span>, <span class="ruby-identifier">password</span>, <span class="ruby-identifier">uri</span> = <span class="ruby-keyword kw">nil</span>)
|
200
|
-
<span class="ruby-ivar">@login</span> = <span class="ruby-identifier">login</span>
|
201
|
-
<span class="ruby-ivar">@password</span> = <span class="ruby-identifier">password</span>
|
202
|
-
<span class="ruby-ivar">@uri</span> = <span class="ruby-identifier">uri</span>
|
203
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@uri</span>.<span class="ruby-identifier">nil?</span>
|
204
|
-
<span class="ruby-keyword kw">begin</span>
|
205
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">const_get</span>(<span class="ruby-identifier">:URL</span>)
|
206
|
-
<span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">NameError</span>
|
207
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>.<span class="ruby-identifier">new</span> <span class="ruby-value str">"You must provide an URL when using Gandi::Base directly"</span>
|
208
|
-
<span class="ruby-keyword kw">end</span>
|
209
|
-
<span class="ruby-keyword kw">end</span>
|
210
|
-
<span class="ruby-keyword kw">end</span>
|
211
|
-
</pre>
|
212
|
-
</div>
|
213
|
-
</div>
|
214
|
-
</div>
|
215
|
-
|
216
|
-
<h3 class="section-bar">Public Instance methods</h3>
|
217
|
-
|
218
|
-
<div id="method-M000055" class="method-detail">
|
219
|
-
<a name="M000055"></a>
|
220
|
-
|
221
|
-
<div class="method-heading">
|
222
|
-
<a href="#M000055" class="method-signature">
|
223
|
-
<span class="method-name">account_balance</span><span class="method-args">()</span>
|
224
|
-
</a>
|
225
|
-
</div>
|
226
|
-
|
227
|
-
<div class="method-description">
|
228
|
-
<p>
|
229
|
-
Current prepaid account balance
|
230
|
-
</p>
|
231
|
-
<p><a class="source-toggle" href="#"
|
232
|
-
onclick="toggleCode('M000055-source');return false;">[Source]</a></p>
|
233
|
-
<div class="method-source-code" id="M000055-source">
|
234
|
-
<pre>
|
235
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 60</span>
|
236
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">account_balance</span>
|
237
|
-
<span class="ruby-identifier">call</span>(<span class="ruby-value str">'account_balance'</span>)
|
238
|
-
<span class="ruby-keyword kw">end</span>
|
239
|
-
</pre>
|
240
|
-
</div>
|
241
|
-
</div>
|
242
|
-
</div>
|
243
|
-
|
244
|
-
<div id="method-M000056" class="method-detail">
|
245
|
-
<a name="M000056"></a>
|
246
|
-
|
247
|
-
<div class="method-heading">
|
248
|
-
<a href="#M000056" class="method-signature">
|
249
|
-
<span class="method-name">account_currency</span><span class="method-args">()</span>
|
250
|
-
</a>
|
251
|
-
</div>
|
252
|
-
|
253
|
-
<div class="method-description">
|
254
|
-
<p>
|
255
|
-
Currency name used with the prepaid account
|
256
|
-
</p>
|
257
|
-
<p><a class="source-toggle" href="#"
|
258
|
-
onclick="toggleCode('M000056-source');return false;">[Source]</a></p>
|
259
|
-
<div class="method-source-code" id="M000056-source">
|
260
|
-
<pre>
|
261
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 65</span>
|
262
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">account_currency</span>
|
263
|
-
<span class="ruby-identifier">call</span>(<span class="ruby-value str">'account_currency'</span>)
|
264
|
-
<span class="ruby-keyword kw">end</span>
|
265
|
-
</pre>
|
266
|
-
</div>
|
267
|
-
</div>
|
268
|
-
</div>
|
269
|
-
|
270
|
-
<div id="method-M000051" class="method-detail">
|
271
|
-
<a name="M000051"></a>
|
272
|
-
|
273
|
-
<div class="method-heading">
|
274
|
-
<a href="#M000051" class="method-signature">
|
275
|
-
<span class="method-name">call</span><span class="method-args">(method, *arguments)</span>
|
276
|
-
</a>
|
277
|
-
</div>
|
278
|
-
|
279
|
-
<div class="method-description">
|
280
|
-
<p>
|
281
|
-
Calls a RPC method, transparently providing the session id
|
282
|
-
</p>
|
283
|
-
<p><a class="source-toggle" href="#"
|
284
|
-
onclick="toggleCode('M000051-source');return false;">[Source]</a></p>
|
285
|
-
<div class="method-source-code" id="M000051-source">
|
286
|
-
<pre>
|
287
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 31</span>
|
288
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">call</span>(<span class="ruby-identifier">method</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">arguments</span>)
|
289
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-value str">"You have to log in before using methods requiring a session id"</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">logged_in?</span>
|
290
|
-
<span class="ruby-identifier">raw_call</span>(<span class="ruby-identifier">method</span>.<span class="ruby-identifier">to_s</span>, <span class="ruby-ivar">@session_id</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">arguments</span>)
|
291
|
-
<span class="ruby-keyword kw">end</span>
|
292
|
-
</pre>
|
293
|
-
</div>
|
294
|
-
</div>
|
295
|
-
</div>
|
296
|
-
|
297
|
-
<div id="method-M000052" class="method-detail">
|
298
|
-
<a name="M000052"></a>
|
299
|
-
|
300
|
-
<div class="method-heading">
|
301
|
-
<a href="#M000052" class="method-signature">
|
302
|
-
<span class="method-name">login</span><span class="method-args">()</span>
|
303
|
-
</a>
|
304
|
-
</div>
|
305
|
-
|
306
|
-
<div class="method-description">
|
307
|
-
<p>
|
308
|
-
Instanciates a rpc handler and log in to the interface to retrieve a
|
309
|
-
session id
|
310
|
-
</p>
|
311
|
-
<p><a class="source-toggle" href="#"
|
312
|
-
onclick="toggleCode('M000052-source');return false;">[Source]</a></p>
|
313
|
-
<div class="method-source-code" id="M000052-source">
|
314
|
-
<pre>
|
315
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 37</span>
|
316
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">login</span>
|
317
|
-
<span class="ruby-ivar">@handler</span> = <span class="ruby-constant">XMLRPC</span><span class="ruby-operator">::</span><span class="ruby-constant">Client</span>.<span class="ruby-identifier">new_from_uri</span>(<span class="ruby-ivar">@uri</span>)
|
318
|
-
<span class="ruby-comment cmt">#Get rid of SSL warnings "peer certificate won't be verified in this SSL session"</span>
|
319
|
-
<span class="ruby-comment cmt">#See http://developer.amazonwebservices.com/connect/thread.jspa?threadID=37139</span>
|
320
|
-
<span class="ruby-comment cmt">#and http://blog.chmouel.com/2008/03/21/ruby-xmlrpc-over-a-self-certified-ssl-with-a-warning/</span>
|
321
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@handler</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-value str">'@http'</span>).<span class="ruby-identifier">use_ssl?</span>
|
322
|
-
<span class="ruby-ivar">@handler</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-value str">'@http'</span>).<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-value str">"@ssl_context"</span>).<span class="ruby-identifier">verify_mode</span> = <span class="ruby-constant">OpenSSL</span><span class="ruby-operator">::</span><span class="ruby-constant">SSL</span><span class="ruby-operator">::</span><span class="ruby-constant">VERIFY_NONE</span>
|
323
|
-
<span class="ruby-keyword kw">end</span>
|
324
|
-
<span class="ruby-ivar">@session_id</span> = <span class="ruby-identifier">raw_call</span>(<span class="ruby-value str">"login"</span>, <span class="ruby-ivar">@login</span>, <span class="ruby-ivar">@password</span>, <span class="ruby-keyword kw">false</span>)
|
325
|
-
<span class="ruby-keyword kw">end</span>
|
326
|
-
</pre>
|
327
|
-
</div>
|
328
|
-
</div>
|
329
|
-
</div>
|
330
|
-
|
331
|
-
<div id="method-M000054" class="method-detail">
|
332
|
-
<a name="M000054"></a>
|
333
|
-
|
334
|
-
<div class="method-heading">
|
335
|
-
<a href="#M000054" class="method-signature">
|
336
|
-
<span class="method-name">password</span><span class="method-args">(password)</span>
|
337
|
-
</a>
|
338
|
-
</div>
|
339
|
-
|
340
|
-
<div class="method-description">
|
341
|
-
<p>
|
342
|
-
Changes <a href="Base.html#M000054">password</a>
|
343
|
-
</p>
|
344
|
-
<p><a class="source-toggle" href="#"
|
345
|
-
onclick="toggleCode('M000054-source');return false;">[Source]</a></p>
|
346
|
-
<div class="method-source-code" id="M000054-source">
|
347
|
-
<pre>
|
348
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 54</span>
|
349
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">password</span>(<span class="ruby-identifier">password</span>)
|
350
|
-
<span class="ruby-ivar">@password</span> = <span class="ruby-identifier">password</span>
|
351
|
-
<span class="ruby-identifier">call</span>(<span class="ruby-value str">"password"</span>, <span class="ruby-identifier">password</span>)
|
352
|
-
<span class="ruby-keyword kw">end</span>
|
353
|
-
</pre>
|
354
|
-
</div>
|
355
|
-
</div>
|
356
|
-
</div>
|
357
|
-
|
358
|
-
<div id="method-M000053" class="method-detail">
|
359
|
-
<a name="M000053"></a>
|
360
|
-
|
361
|
-
<div class="method-heading">
|
362
|
-
<a href="#M000053" class="method-signature">
|
363
|
-
<span class="method-name">su</span><span class="method-args">(handle)</span>
|
364
|
-
</a>
|
365
|
-
</div>
|
366
|
-
|
367
|
-
<div class="method-description">
|
368
|
-
<p>
|
369
|
-
Gets a <a href="Base.html#M000050">new</a> session id by switching to
|
370
|
-
another handle
|
371
|
-
</p>
|
372
|
-
<p><a class="source-toggle" href="#"
|
373
|
-
onclick="toggleCode('M000053-source');return false;">[Source]</a></p>
|
374
|
-
<div class="method-source-code" id="M000053-source">
|
375
|
-
<pre>
|
376
|
-
<span class="ruby-comment cmt"># File lib/gandi/base.rb, line 49</span>
|
377
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">su</span>(<span class="ruby-identifier">handle</span>)
|
378
|
-
<span class="ruby-ivar">@session_id</span> = <span class="ruby-identifier">call</span>(<span class="ruby-value str">"su"</span>, <span class="ruby-identifier">handle</span>)
|
379
|
-
<span class="ruby-keyword kw">end</span>
|
380
|
-
</pre>
|
381
|
-
</div>
|
382
|
-
</div>
|
383
|
-
</div>
|
384
|
-
|
385
|
-
|
386
|
-
</div>
|
387
|
-
|
388
|
-
|
389
|
-
</div>
|
390
|
-
|
391
|
-
|
392
|
-
<div id="validator-badges">
|
393
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
394
|
-
</div>
|
395
|
-
|
396
|
-
</body>
|
397
|
-
</html>
|
@@ -1,111 +0,0 @@
|
|
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: Gandi::DataError</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">Gandi::DataError</td>
|
54
|
-
</tr>
|
55
|
-
<tr class="top-aligned-row">
|
56
|
-
<td><strong>In:</strong></td>
|
57
|
-
<td>
|
58
|
-
<a href="../../files/lib/gandi_rb.html">
|
59
|
-
lib/gandi.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
|
-
ArgumentError
|
69
|
-
</td>
|
70
|
-
</tr>
|
71
|
-
</table>
|
72
|
-
</div>
|
73
|
-
<!-- banner header -->
|
74
|
-
|
75
|
-
<div id="bodyContent">
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
<div id="contextContent">
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
</div>
|
84
|
-
|
85
|
-
|
86
|
-
</div>
|
87
|
-
|
88
|
-
|
89
|
-
<!-- if includes -->
|
90
|
-
|
91
|
-
<div id="section">
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
<!-- if method_list -->
|
101
|
-
|
102
|
-
|
103
|
-
</div>
|
104
|
-
|
105
|
-
|
106
|
-
<div id="validator-badges">
|
107
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
108
|
-
</div>
|
109
|
-
|
110
|
-
</body>
|
111
|
-
</html>
|