incubator-deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@apache.org
Subject svn commit: r1003045 [11/24] - in /incubator/deltacloud/trunk: server/ site/api-docs/ site/api-docs/CloudClient/ site/api-docs/Deltacloud/ site/api-docs/Deltacloud/BaseDriver/ site/api-docs/Deltacloud/Drivers/ site/api-docs/Deltacloud/Drivers/Azure/ si...
Date Thu, 30 Sep 2010 12:48:04 GMT
Added: incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingClient.html
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingClient.html?rev=1003045&view=auto
==============================================================================
--- incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingClient.html (added)
+++ incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingClient.html Thu Sep 30 12:48:00 2010
@@ -0,0 +1,571 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+  <head>
+    <meta name="Content-Type" content="text/html; charset=utf8" />
+<title>Class: Deltacloud::Drivers::RimuHosting::RimuHostingClient</title>
+<link rel="stylesheet" href="../../../css/style.css" type="text/css" media="screen" charset="utf-8" />
+<link rel="stylesheet" href="../../../css/common.css" type="text/css" media="screen" charset="utf-8" />
+
+<script type="text/javascript" charset="utf-8">
+  relpath = '../../..';
+  if (relpath != '') relpath += '/';
+</script>
+<script type="text/javascript" charset="utf-8" src="../../../js/jquery.js"></script>
+<script type="text/javascript" charset="utf-8" src="../../../js/app.js"></script>
+
+  </head>
+  <body>
+    <script type="text/javascript" charset="utf-8">
+      if (window.top.frames.main) document.body.className = 'frames';
+    </script>
+    
+    <div id="header">
+      <div id="menu">
+  
+    <a href="../../../_index.html">Index (R)</a> &raquo; 
+    <span class='title'><span class='object_link'><a href="../../../Deltacloud.html" title="Deltacloud (module)">Deltacloud</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../../Drivers.html" title="Deltacloud::Drivers (module)">Drivers</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../RimuHosting.html" title="Deltacloud::Drivers::RimuHosting (module)">RimuHosting</a></span></span>
+     &raquo; 
+    <span class="title">RimuHostingClient</span>
+  
+  
+  <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
+</div>
+
+      <div id="search">
+  <a id="class_list_link" href="#">Class List</a>
+  <a id="method_list_link" href="#">Method List</a>
+  <a id ="file_list_link" href="#">File List</a>
+</div>
+
+      <div class="clear"></div>
+    </div>
+    
+    <iframe id="search_frame"></iframe>
+    
+    <div id="content"><h1>Class: Deltacloud::Drivers::RimuHosting::RimuHostingClient
+  
+  
+  
+</h1>
+
+<dl class="box">
+  
+    <dt class="r1">Inherits:</dt>
+    <dd class="r1">
+      <span class="inheritName">Object</span>
+      
+        <ul class="fullTree">
+          <li>Object</li>
+          
+            <li class="next">Deltacloud::Drivers::RimuHosting::RimuHostingClient</li>
+          
+        </ul>
+        <a href="#" class="inheritanceTree">show all</a>
+      
+      </dd>
+    
+  
+  
+    
+  
+    
+  
+  
+  
+    <dt class="r2 last">Defined in:</dt>
+    <dd class="r2 last">lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb</dd>
+  
+</dl>
+<div class="clear"></div>
+
+
+
+
+  
+    <h2>
+      Instance Method Summary
+      <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
+    </h2>
+
+    <ul class="summary">
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#create_server-instance_method" title="#create_server (instance method)">- (Object) <strong>create_server</strong>(image_id, plan_code, name) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#delete_server-instance_method" title="#delete_server (instance method)">- (Object) <strong>delete_server</strong>(id) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#initialize-instance_method" title="#initialize (instance method)">- (RimuHostingClient) <strong>initialize</strong>(credentials, baseuri = 'https://rimuhosting.com/r') </a>
+    
+
+    
+  </span>
+  
+    <span class="note title constructor">constructor</span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'><p>
+A new instance of RimuHostingClient.
+</p>
+</div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#list_images-instance_method" title="#list_images (instance method)">- (Object) <strong>list_images</strong> </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#list_nodes-instance_method" title="#list_nodes (instance method)">- (Object) <strong>list_nodes</strong> </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#list_plans-instance_method" title="#list_plans (instance method)">- (Object) <strong>list_plans</strong> </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#request-instance_method" title="#request (instance method)">- (Object) <strong>request</strong>(resource, data = '', method = 'GET') </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#set_server_state-instance_method" title="#set_server_state (instance method)">- (Object) <strong>set_server_state</strong>(id, state) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+    </ul>
+  
+
+<div id="constructor_details" class="method_details_list">
+  <h2>Constructor Details</h2>
+  
+    <div class="method_details first">
+  <p class="signature first" id="initialize-instance_method">
+  
+    - (<tt><span class='object_link'><a href="" title="Deltacloud::Drivers::RimuHosting::RimuHostingClient (class)">RimuHostingClient</a></span></tt>) <strong>initialize</strong>(credentials, baseuri = 'https://rimuhosting.com/r') 
+  
+
+  
+</p><div class="docstring">
+  <div class="discussion">
+    <p>
+A new instance of RimuHostingClient
+</p>
+
+
+  </div>
+</div>
+<div class="tags">
+  
+</div><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+31
+32
+33
+34
+35
+36</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 31</span>
+
+<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span> <span class='comma token'>,</span><span class='baseuri identifier id'>baseuri</span> <span class='assign token'>=</span> <span class='string val'>'https://rimuhosting.com/r'</span><span class='rparen token'>)</span>
+  <span class='@uri ivar id'>@uri</span> <span class='assign token'>=</span> <span class='URI constant id'>URI</span><span class='dot token'>.</span><span class='parse identifier id'>parse</span><span class='lparen token'>(</span><span class='baseuri identifier id'>baseuri</span><span class='rparen token'>)</span>
+  <span class='@service ivar id'>@service</span> <span class='assign token'>=</span> <span class='Net constant id'>Net</span><span class='colon2 op'>::</span><span class='HTTP constant id'>HTTP</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@uri ivar id'>@uri</span><span class='dot token'>.</span><span class='host identifier id'>host</span><span class='comma token'>,</span> <span class='@uri ivar id'>@uri</span><span class='dot token'>.</span><span class='port identifier id'>port</span><span class='rparen token'>)</span>
+  <span class='@service ivar id'>@service</span><span class='dot token'>.</span><span class='use_ssl identifier id'>use_ssl</span> <span class='assign token'>=</span> <span class='true true kw'>true</span>
+  <span class='@auth ivar id'>@auth</span> <span class='assign token'>=</span> <span class='dstring node'>&quot;rimuhosting apikey=#{credentials.password}&quot;</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+  
+</div>
+
+
+  <div id="instance_method_details" class="method_details_list">
+    <h2>Instance Method Details</h2>
+    
+    
+      <div class="method_details first">
+  <p class="signature first" id="create_server-instance_method">
+  
+    - (<tt>Object</tt>) <strong>create_server</strong>(image_id, plan_code, name) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+76
+77
+78
+79
+80</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 76</span>
+
+<span class='def def kw'>def</span> <span class='create_server identifier id'>create_server</span><span class='lparen token'>(</span><span class='image_id identifier id'>image_id</span><span class='comma token'>,</span> <span class='plan_code identifier id'>plan_code</span><span class='comma token'>,</span> <span class='name identifier id'>name</span><span class='rparen token'>)</span>
+  <span class='json identifier id'>json</span> <span class='assign token'>=</span> <span class='lbrace token'>{</span><span class='symbol val'>:new_vps</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='lbrace token'>{</span><span class='symbol val'>:instantiation_options</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='lbrace token'>{</span><span class='symbol val'>:domain_name</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='symbol val'>:distro</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='image_id identifier id'>image_id</span><span class='rbrace token'>}</span><span class='comma token'>,</span>
+                      <span class='symbol val'>:pricing_plan_code</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='plan_code identifier id'>plan_code</span><span class='rbrace token'>}</span><span class='rbrace token'>}</span><span class='dot token'>.</span><span class='to_json identifier id'>to_json</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='string val'>'/orders/new-vps'</span><span class='comma token'>,</span><span class='json identifier id'>json</span><span class='comma token'>,</span> <span class='string val'>'POST'</span><span class='rparen token'>)</span><span class='lbrack token'>[</span><span class='symbol val'>:about_order</span><span class='rbrack token'>]</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="delete_server-instance_method">
+  
+    - (<tt>Object</tt>) <strong>delete_server</strong>(id) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+72
+73
+74</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 72</span>
+
+<span class='def def kw'>def</span> <span class='delete_server identifier id'>delete_server</span><span class='lparen token'>(</span><span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='dstring node'>&quot;/orders/order-#{id}-a/vps&quot;</span><span class='comma token'>,</span><span class='string val'>''</span><span class='comma token'>,</span> <span class='string val'>'DELETE'</span><span class='rparen token'>)</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="list_images-instance_method">
+  
+    - (<tt>Object</tt>) <strong>list_images</strong> 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+55
+56
+57</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 55</span>
+
+<span class='def def kw'>def</span> <span class='list_images identifier id'>list_images</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='string val'>'/distributions'</span><span class='rparen token'>)</span><span class='lbrack token'>[</span><span class='string val'>&quot;distro_infos&quot;</span><span class='rbrack token'>]</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="list_nodes-instance_method">
+  
+    - (<tt>Object</tt>) <strong>list_nodes</strong> 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+63
+64
+65</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 63</span>
+
+<span class='def def kw'>def</span> <span class='list_nodes identifier id'>list_nodes</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='string val'>'/orders;include_inactive=N'</span><span class='rparen token'>)</span><span class='lbrack token'>[</span><span class='string val'>&quot;about_orders&quot;</span><span class='rbrack token'>]</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="list_plans-instance_method">
+  
+    - (<tt>Object</tt>) <strong>list_plans</strong> 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+59
+60
+61</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 59</span>
+
+<span class='def def kw'>def</span> <span class='list_plans identifier id'>list_plans</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='string val'>'/pricing-plans;server-type=VPS'</span><span class='rparen token'>)</span><span class='lbrack token'>[</span><span class='string val'>&quot;pricing_plan_infos&quot;</span><span class='rbrack token'>]</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="request-instance_method">
+  
+    - (<tt>Object</tt>) <strong>request</strong>(resource, data = '', method = 'GET') 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+38
+39
+40
+41
+42
+43
+44
+45
+46
+47
+48
+49
+50
+51
+52
+53</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 38</span>
+
+<span class='def def kw'>def</span> <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='resource identifier id'>resource</span><span class='comma token'>,</span> <span class='data identifier id'>data</span><span class='assign token'>=</span><span class='string val'>''</span><span class='comma token'>,</span> <span class='method identifier id'>method</span><span class='assign token'>=</span><span class='string val'>'GET'</span><span class='rparen token'>)</span>
+  <span class='headers identifier id'>headers</span> <span class='assign token'>=</span> <span class='lbrace token'>{</span><span class='string val'>&quot;Accept&quot;</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;application/json&quot;</span><span class='comma token'>,</span> <span class='string val'>&quot;Content-Type&quot;</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;application/json&quot;</span><span class='rbrace token'>}</span>
+  <span class='if if kw'>if</span><span class='lparen token'>(</span><span class='notop op'>!</span><span class='@auth ivar id'>@auth</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span><span class='rparen token'>)</span>
+    <span class='headers identifier id'>headers</span><span class='lbrack token'>[</span><span class='string val'>&quot;Authorization&quot;</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='@auth ivar id'>@auth</span>
+  <span class='end end kw'>end</span>
+  <span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='@service ivar id'>@service</span><span class='dot token'>.</span><span class='send_request identifier id'>send_request</span><span class='lparen token'>(</span><span class='method identifier id'>method</span><span class='comma token'>,</span> <span class='@uri ivar id'>@uri</span><span class='dot token'>.</span><span class='path identifier id'>path</span> <span class='plus op'>+</span> <span class='resource identifier id'>resource</span><span class='comma token'>,</span> <span class='data identifier id'>data</span><span class='comma token'>,</span> <span class='headers identifier id'>headers</span><span class='rparen token'>)</span>
+       <span class='puts identifier id'>puts</span> <span class='r identifier id'>r</span><span class='dot token'>.</span><span class='body identifier id'>body</span>
+  <span class='res identifier id'>res</span> <span class='assign token'>=</span> <span class='JSON constant id'>JSON</span><span class='dot token'>.</span><span class='parse identifier id'>parse</span><span class='lparen token'>(</span><span class='r identifier id'>r</span><span class='dot token'>.</span><span class='body identifier id'>body</span><span class='rparen token'>)</span>
+  <span class='res identifier id'>res</span> <span class='assign token'>=</span> <span class='res identifier id'>res</span><span class='lbrack token'>[</span><span class='res identifier id'>res</span><span class='dot token'>.</span><span class='keys identifier id'>keys</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span><span class='rbrack token'>]</span>
+
+  <span class='if if kw'>if</span><span class='lparen token'>(</span><span class='res identifier id'>res</span><span class='lbrack token'>[</span><span class='string val'>'response_type'</span><span class='rbrack token'>]</span> <span class='eq op'>==</span> <span class='string val'>&quot;ERROR&quot;</span> <span class='and and kw'>and</span> <span class='lparen token'>(</span> <span class='lparen token'>(</span><span class='res identifier id'>res</span><span class='lbrack token'>[</span><span class='string val'>'error_info'</span><span class='rbrack token'>]</span><span class='lbrack token'>[</span><span class='string val'>'error_class'</span><span class='rbrack token'>]</span> <span class='eq op'>==</span> <span class='string val'>&quot;PermissionException&quot;</span><span class='rparen token'>)</span> <span class='or or kw'>or</span>
+             <span class='lparen token'>(</span><span class='res identifier id'>res</span><span class='lbrack token'>[</span><span class='string val'>'error_info'</span><span class='rbrack token'>]</span><span class='lbrack token'>[</span><span class='string val'>'error_class'</span><span class='rbrack token'>]</span> <span class='eq op'>==</span> <span class='string val'>&quot;LoginRequired&quot;</span><span class='rparen token'>)</span> <span class='rparen token'>)</span><span class='rparen token'>)</span> 
+    <span class='raise identifier id'>raise</span> <span class='Deltacloud constant id'>Deltacloud</span><span class='colon2 op'>::</span><span class='AuthException constant id'>AuthException</span><span class='dot token'>.</span><span class='new identifier id'>new</span>
+  <span class='end end kw'>end</span>
+  <span class='res identifier id'>res</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="set_server_state-instance_method">
+  
+    - (<tt>Object</tt>) <strong>set_server_state</strong>(id, state) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+67
+68
+69
+70</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_client.rb', line 67</span>
+
+<span class='def def kw'>def</span> <span class='set_server_state identifier id'>set_server_state</span><span class='lparen token'>(</span><span class='id identifier id'>id</span><span class='comma token'>,</span> <span class='state identifier id'>state</span><span class='rparen token'>)</span>
+  <span class='json identifier id'>json</span> <span class='assign token'>=</span> <span class='lbrace token'>{</span><span class='string val'>&quot;reboot_request&quot;</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='lbrace token'>{</span><span class='string val'>&quot;running_state&quot;</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='state identifier id'>state</span><span class='rbrace token'>}</span><span class='rbrace token'>}</span><span class='dot token'>.</span><span class='to_json identifier id'>to_json</span>
+  <span class='request identifier id'>request</span><span class='lparen token'>(</span><span class='dstring node'>&quot;/orders/order-#{id}-a/vps/running-state&quot;</span><span class='comma token'>,</span> <span class='json identifier id'>json</span><span class='comma token'>,</span> <span class='string val'>'PUT'</span><span class='rparen token'>)</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+  </div>
+
+</div>
+    
+    <div id="footer">
+  Generated on Thu Sep 30 14:43:54 2010 by 
+  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
+  0.6.1 (ruby-1.8.6).
+</div>
+
+  </body>
+</html>
\ No newline at end of file

Added: incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingDriver.html
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingDriver.html?rev=1003045&view=auto
==============================================================================
--- incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingDriver.html (added)
+++ incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/RimuHosting/RimuHostingDriver.html Thu Sep 30 12:48:00 2010
@@ -0,0 +1,825 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+  <head>
+    <meta name="Content-Type" content="text/html; charset=utf8" />
+<title>Class: Deltacloud::Drivers::RimuHosting::RimuHostingDriver</title>
+<link rel="stylesheet" href="../../../css/style.css" type="text/css" media="screen" charset="utf-8" />
+<link rel="stylesheet" href="../../../css/common.css" type="text/css" media="screen" charset="utf-8" />
+
+<script type="text/javascript" charset="utf-8">
+  relpath = '../../..';
+  if (relpath != '') relpath += '/';
+</script>
+<script type="text/javascript" charset="utf-8" src="../../../js/jquery.js"></script>
+<script type="text/javascript" charset="utf-8" src="../../../js/app.js"></script>
+
+  </head>
+  <body>
+    <script type="text/javascript" charset="utf-8">
+      if (window.top.frames.main) document.body.className = 'frames';
+    </script>
+    
+    <div id="header">
+      <div id="menu">
+  
+    <a href="../../../_index.html">Index (R)</a> &raquo; 
+    <span class='title'><span class='object_link'><a href="../../../Deltacloud.html" title="Deltacloud (module)">Deltacloud</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../../Drivers.html" title="Deltacloud::Drivers (module)">Drivers</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../RimuHosting.html" title="Deltacloud::Drivers::RimuHosting (module)">RimuHosting</a></span></span>
+     &raquo; 
+    <span class="title">RimuHostingDriver</span>
+  
+  
+  <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
+</div>
+
+      <div id="search">
+  <a id="class_list_link" href="#">Class List</a>
+  <a id="method_list_link" href="#">Method List</a>
+  <a id ="file_list_link" href="#">File List</a>
+</div>
+
+      <div class="clear"></div>
+    </div>
+    
+    <iframe id="search_frame"></iframe>
+    
+    <div id="content"><h1>Class: Deltacloud::Drivers::RimuHosting::RimuHostingDriver
+  
+  
+  
+</h1>
+
+<dl class="box">
+  
+    <dt class="r1">Inherits:</dt>
+    <dd class="r1">
+      <span class="inheritName"><span class='object_link'><a href="../../BaseDriver.html" title="Deltacloud::BaseDriver (class)">BaseDriver</a></span></span>
+      
+        <ul class="fullTree">
+          <li>Object</li>
+          
+            <li class="next"><span class='object_link'><a href="../../BaseDriver.html" title="Deltacloud::BaseDriver (class)">BaseDriver</a></span></li>
+          
+            <li class="next">Deltacloud::Drivers::RimuHosting::RimuHostingDriver</li>
+          
+        </ul>
+        <a href="#" class="inheritanceTree">show all</a>
+      
+      </dd>
+    
+  
+  
+    
+  
+    
+  
+  
+  
+    <dt class="r2 last">Defined in:</dt>
+    <dd class="r2 last">lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb</dd>
+  
+</dl>
+<div class="clear"></div>
+
+
+
+  
+  
+  
+  
+
+  
+    <h2>
+      Instance Method Summary
+      <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
+    </h2>
+
+    <ul class="summary">
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#convert_srv_to_instance-instance_method" title="#convert_srv_to_instance (instance method)">- (Object) <strong>convert_srv_to_instance</strong>(inst) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#create_instance-instance_method" title="#create_instance (instance method)">- (Object) <strong>create_instance</strong>(credentials, image_id, opts) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#destroy_instance-instance_method" title="#destroy_instance (instance method)">- (Object) <strong>destroy_instance</strong>(credentials, id) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#hardware_profiles-instance_method" title="#hardware_profiles (instance method)">- (Object) <strong>hardware_profiles</strong>(credentials, opts = nil) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#images-instance_method" title="#images (instance method)">- (Object) <strong>images</strong>(credentails, opts = nil) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#instances-instance_method" title="#instances (instance method)">- (Object) <strong>instances</strong>(credentials, opts = nil) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#realms-instance_method" title="#realms (instance method)">- (Object) <strong>realms</strong>(credentials, opts = nil) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#reboot_instance-instance_method" title="#reboot_instance (instance method)">- (Object) <strong>reboot_instance</strong>(credentials, id) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#safely-instance_method" title="#safely (instance method)">- (Object) <strong>safely</strong>(&amp;block) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#start_instance-instance_method" title="#start_instance (instance method)">- (Object) <strong>start_instance</strong>(credentials, id) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+        <li class="public ">
+  <span class="summary_signature">
+    
+      <a href="#stop_instance-instance_method" title="#stop_instance (instance method)">- (Object) <strong>stop_instance</strong>(credentials, id) </a>
+    
+
+    
+  </span>
+  
+  
+  
+  
+  
+  
+
+  
+    <span class="summary_desc"><div class='inline'></div></span>
+  
+</li>
+
+      
+    </ul>
+  
+
+
+  
+  
+  
+  
+  
+  
+  
+  <h3 class="inherited">Methods inherited from <span class='object_link'><a href="../../BaseDriver.html" title="Deltacloud::BaseDriver (class)">BaseDriver</a></span></h3>
+  <p class="inherited"><span class='object_link'><a href="../../BaseDriver.html#blob-instance_method" title="Deltacloud::BaseDriver#blob (method)">#blob</a></span>, <span class='object_link'><a href="../../BaseDriver.html#blob_data-instance_method" title="Deltacloud::BaseDriver#blob_data (method)">#blob_data</a></span>, <span class='object_link'><a href="../../BaseDriver.html#blobs-instance_method" title="Deltacloud::BaseDriver#blobs (method)">#blobs</a></span>, <span class='object_link'><a href="../../BaseDriver.html#bucket-instance_method" title="Deltacloud::BaseDriver#bucket (method)">#bucket</a></span>, <span class='object_link'><a href="../../BaseDriver.html#buckets-instance_method" title="Deltacloud::BaseDriver#buckets (method)">#buckets</a></span>, <span class='object_link'><a href="../../BaseDriver.html#catched_exceptions_list-instance_method" title="Deltacloud::BaseDriver#catched_exceptions_list (method)">#catched_exceptions_list</a></span>, <span class='object_link
 '><a href="../../BaseDriver.html#create_bucket-instance_method" title="Deltacloud::BaseDriver#create_bucket (method)">#create_bucket</a></span>, <span class='object_link'><a href="../../BaseDriver.html#declare_feature-class_method" title="Deltacloud::BaseDriver.declare_feature (method)">declare_feature</a></span>, <span class='object_link'><a href="../../BaseDriver.html#define_hardware_profile-class_method" title="Deltacloud::BaseDriver.define_hardware_profile (method)">define_hardware_profile</a></span>, <span class='object_link'><a href="../../BaseDriver.html#define_instance_states-class_method" title="Deltacloud::BaseDriver.define_instance_states (method)">define_instance_states</a></span>, <span class='object_link'><a href="../../BaseDriver.html#delete_bucket-instance_method" title="Deltacloud::BaseDriver#delete_bucket (method)">#delete_bucket</a></span>, <span class='object_link'><a href="../../BaseDriver.html#feature-class_method" title="Deltacloud::BaseDriver.feature 
 (method)">feature</a></span>, <span class='object_link'><a href="../../BaseDriver.html#feature_decl_for-class_method" title="Deltacloud::BaseDriver.feature_decl_for (method)">feature_decl_for</a></span>, <span class='object_link'><a href="../../BaseDriver.html#feature_decls-class_method" title="Deltacloud::BaseDriver.feature_decls (method)">feature_decls</a></span>, <span class='object_link'><a href="../../BaseDriver.html#features-instance_method" title="Deltacloud::BaseDriver#features (method)">#features</a></span>, <span class='object_link'><a href="../../BaseDriver.html#features-class_method" title="Deltacloud::BaseDriver.features (method)">features</a></span>, <span class='object_link'><a href="../../BaseDriver.html#filter_hardware_profiles-instance_method" title="Deltacloud::BaseDriver#filter_hardware_profiles (method)">#filter_hardware_profiles</a></span>, <span class='object_link'><a href="../../BaseDriver.html#filter_on-instance_method" title="Deltacloud::BaseDriver#
 filter_on (method)">#filter_on</a></span>, <span class='object_link'><a href="../../BaseDriver.html#find_hardware_profile-instance_method" title="Deltacloud::BaseDriver#find_hardware_profile (method)">#find_hardware_profile</a></span>, <span class='object_link'><a href="../../BaseDriver.html#hardware_profile-instance_method" title="Deltacloud::BaseDriver#hardware_profile (method)">#hardware_profile</a></span>, <span class='object_link'><a href="../../BaseDriver.html#hardware_profiles-class_method" title="Deltacloud::BaseDriver.hardware_profiles (method)">hardware_profiles</a></span>, <span class='object_link'><a href="../../BaseDriver.html#has_collection%3F-instance_method" title="Deltacloud::BaseDriver#has_collection? (method)">#has_collection?</a></span>, <span class='object_link'><a href="../../BaseDriver.html#image-instance_method" title="Deltacloud::BaseDriver#image (method)">#image</a></span>, <span class='object_link'><a href="../../BaseDriver.html#instance-instance_m
 ethod" title="Deltacloud::BaseDriver#instance (method)">#instance</a></span>, <span class='object_link'><a href="../../BaseDriver.html#instance_actions_for-instance_method" title="Deltacloud::BaseDriver#instance_actions_for (method)">#instance_actions_for</a></span>, <span class='object_link'><a href="../../BaseDriver.html#instance_state_machine-class_method" title="Deltacloud::BaseDriver.instance_state_machine (method)">instance_state_machine</a></span>, <span class='object_link'><a href="../../BaseDriver.html#instance_state_machine-instance_method" title="Deltacloud::BaseDriver#instance_state_machine (method)">#instance_state_machine</a></span>, <span class='object_link'><a href="../../BaseDriver.html#realm-instance_method" title="Deltacloud::BaseDriver#realm (method)">#realm</a></span>, <span class='object_link'><a href="../../BaseDriver.html#storage_snapshot-instance_method" title="Deltacloud::BaseDriver#storage_snapshot (method)">#storage_snapshot</a></span>, <span clas
 s='object_link'><a href="../../BaseDriver.html#storage_snapshots-instance_method" title="Deltacloud::BaseDriver#storage_snapshots (method)">#storage_snapshots</a></span>, <span class='object_link'><a href="../../BaseDriver.html#storage_volume-instance_method" title="Deltacloud::BaseDriver#storage_volume (method)">#storage_volume</a></span>, <span class='object_link'><a href="../../BaseDriver.html#storage_volumes-instance_method" title="Deltacloud::BaseDriver#storage_volumes (method)">#storage_volumes</a></span>, <span class='object_link'><a href="../../BaseDriver.html#supported_collections-instance_method" title="Deltacloud::BaseDriver#supported_collections (method)">#supported_collections</a></span></p>
+
+
+  <div id="instance_method_details" class="method_details_list">
+    <h2>Instance Method Details</h2>
+    
+    
+      <div class="method_details first">
+  <p class="signature first" id="convert_srv_to_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>convert_srv_to_instance</strong>(inst) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+124
+125
+126
+127
+128
+129
+130
+131
+132
+133
+134
+135
+136
+137
+138</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 124</span>
+
+<span class='def def kw'>def</span> <span class='convert_srv_to_instance identifier id'>convert_srv_to_instance</span><span class='lparen token'>(</span> <span class='inst identifier id'>inst</span> <span class='rparen token'>)</span>
+  <span class='Instance constant id'>Instance</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='lbrace token'>{</span>
+          <span class='symbol val'>:id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='inst identifier id'>inst</span><span class='lbrack token'>[</span><span class='string val'>&quot;order_oid&quot;</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='comma token'>,</span>
+          <span class='symbol val'>:name</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='inst identifier id'>inst</span><span class='lbrack token'>[</span><span class='string val'>&quot;domain_name&quot;</span><span class='rbrack token'>]</span><span class='comma token'>,</span>
+          <span class='symbol val'>:image_id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;lenny&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:state</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;RUNNING&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:name</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='inst identifier id'>inst</span><span class='lbrack token'>[</span><span class='string val'>&quot;domain_name&quot;</span><span class='rbrack token'>]</span><span class='comma token'>,</span>
+          <span class='symbol val'>:realm_id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;RH&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:owner_id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;root&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:instance_profile</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='InstanceProfile constant id'>InstanceProfile</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='string val'>&quot;none&quot;</span><span class='rparen token'>)</span><span class='comma token'>,</span>
+          <span class='symbol val'>:actions</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='instance_actions_for identifier id'>instance_actions_for</span><span class='lparen token'>(</span><span class='string val'>&quot;RUNNING&quot;</span><span class='rparen token'>)</span><span class='comma token'>,</span>
+          <span class='symbol val'>:public_addresses</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='inst identifier id'>inst</span><span class='lbrack token'>[</span><span class='string val'>&quot;allocated_ips&quot;</span><span class='rbrack token'>]</span><span class='lbrack token'>[</span><span class='string val'>&quot;primary_ip&quot;</span><span class='rbrack token'>]</span><span class='comma token'>,</span>
+          <span class='symbol val'>:launch_time</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='inst identifier id'>inst</span><span class='lbrack token'>[</span><span class='string val'>&quot;billing_info&quot;</span><span class='rbrack token'>]</span><span class='lbrack token'>[</span><span class='string val'>&quot;order_date&quot;</span><span class='rbrack token'>]</span><span class='lbrack token'>[</span><span class='string val'>&quot;iso_format&quot;</span><span class='rbrack token'>]</span>
+  <span class='rbrace token'>}</span><span class='rparen token'>)</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="create_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>create_instance</strong>(credentials, image_id, opts) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+111
+112
+113
+114
+115
+116
+117
+118
+119
+120
+121
+122</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 111</span>
+
+<span class='def def kw'>def</span> <span class='create_instance identifier id'>create_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='image_id identifier id'>image_id</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='rparen token'>)</span>
+   <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+  <span class='comment val'># really need to raise an exception here.</span>
+  <span class='hwp_id identifier id'>hwp_id</span> <span class='assign token'>=</span> <span class='opts identifier id'>opts</span><span class='lbrack token'>[</span><span class='symbol val'>:hwp_id</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='integer val'>1</span>
+  <span class='comment val'># really bad, but at least its a fqdn</span>
+  <span class='name identifier id'>name</span> <span class='assign token'>=</span> <span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> <span class='plus op'>+</span> <span class='string val'>'.com'</span>
+  <span class='if if kw'>if</span> <span class='lparen token'>(</span><span class='opts identifier id'>opts</span><span class='lbrack token'>[</span><span class='symbol val'>:name</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='then then kw'>then</span>
+    <span class='name identifier id'>name</span> <span class='assign token'>=</span> <span class='opts identifier id'>opts</span><span class='lbrack token'>[</span><span class='symbol val'>:name</span><span class='rbrack token'>]</span>
+  <span class='end end kw'>end</span>
+  <span class='convert_srv_to_instance identifier id'>convert_srv_to_instance</span><span class='lparen token'>(</span><span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='create_server identifier id'>create_server</span><span class='lparen token'>(</span><span class='image_id identifier id'>image_id</span><span class='comma token'>,</span> <span class='hwp_id identifier id'>hwp_id</span><span class='comma token'>,</span> <span class='name identifier id'>name</span><span class='rparen token'>)</span><span class='rparen token'>)</span>
+
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="destroy_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>destroy_instance</strong>(credentials, id) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+104
+105
+106
+107
+108
+109</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 104</span>
+
+<span class='def def kw'>def</span> <span class='destroy_instance identifier id'>destroy_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+    <span class='return return kw'>return</span> <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='delete_server identifier id'>delete_server</span><span class='lparen token'>(</span><span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='end end kw'>end</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="hardware_profiles-instance_method">
+  
+    - (<tt>Object</tt>) <strong>hardware_profiles</strong>(credentials, opts = nil) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+49
+50
+51
+52
+53
+54
+55
+56
+57
+58
+59
+60
+61
+62
+63
+64</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 49</span>
+
+<span class='def def kw'>def</span> <span class='hardware_profiles identifier id'>hardware_profiles</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span> <span class='assign token'>=</span> <span class='nil nil kw'>nil</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+    <span class='results identifier id'>results</span> <span class='assign token'>=</span> <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='list_plans identifier id'>list_plans</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='plan identifier id'>plan</span><span class='bitor op'>|</span>
+      <span class='comment val'># FIXME: x86 is not a valid architecture; what is Rimu offering ?</span>
+      <span class='comment val'># FIXME: VPS plans offer a range of memory/storage, but that's</span>
+      <span class='comment val'>#        not contained in hte pricing_plan_infos</span>
+      <span class='HardwareProfile constant id'>HardwareProfile</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='plan identifier id'>plan</span><span class='lbrack token'>[</span><span class='string val'>&quot;pricing_plan_code&quot;</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='do do kw'>do</span>
+        <span class='memory identifier id'>memory</span> <span class='plan identifier id'>plan</span><span class='lbrack token'>[</span><span class='string val'>&quot;minimum_memory_mb&quot;</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span>
+        <span class='storage identifier id'>storage</span> <span class='plan identifier id'>plan</span><span class='lbrack token'>[</span><span class='string val'>&quot;minimum_disk_gb&quot;</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='to_i identifier id'>to_i</span>
+        <span class='architecture identifier id'>architecture</span> <span class='string val'>&quot;x86&quot;</span>
+      <span class='end end kw'>end</span>
+    <span class='end end kw'>end</span>
+  <span class='end end kw'>end</span>
+  <span class='filter_hardware_profiles identifier id'>filter_hardware_profiles</span><span class='lparen token'>(</span><span class='results identifier id'>results</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='rparen token'>)</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="images-instance_method">
+  
+    - (<tt>Object</tt>) <strong>images</strong>(credentails, opts = nil) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+31
+32
+33
+34
+35
+36
+37
+38
+39
+40
+41
+42
+43
+44
+45
+46
+47</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 31</span>
+
+<span class='def def kw'>def</span> <span class='images identifier id'>images</span><span class='lparen token'>(</span><span class='credentails identifier id'>credentails</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='assign token'>=</span><span class='nil nil kw'>nil</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentails identifier id'>credentails</span><span class='rparen token'>)</span>
+    <span class='images identifier id'>images</span> <span class='assign token'>=</span> <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='list_images identifier id'>list_images</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span> <span class='image identifier id'>image</span> <span class='bitor op'>|</span>
+      <span class='Image constant id'>Image</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='lbrace token'>{</span>
+              <span class='symbol val'>:id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='image identifier id'>image</span><span class='lbrack token'>[</span><span class='string val'>&quot;distro_code&quot;</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='gsub identifier id'>gsub</span><span class='lparen token'>(</span><span class='regexp val'>/\./</span><span class='comma token'>,</span><span class='string val'>&quot;-&quot;</span><span class='rparen token'>)</span><span class='comma token'>,</span>
+              <span class='symbol val'>:name</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='image identifier id'>image</span><span class='lbrack token'>[</span><span class='string val'>&quot;distro_code&quot;</span><span class='rbrack token'>]</span><span class='comma token'>,</span>
+              <span class='symbol val'>:description</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='image identifier id'>image</span><span class='lbrack token'>[</span><span class='string val'>&quot;distro_description&quot;</span><span class='rbrack token'>]</span><span class='comma token'>,</span>
+              <span class='symbol val'>:owner_id</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;root&quot;</span><span class='comma token'>,</span>
+              <span class='symbol val'>:architecture</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;x86&quot;</span>
+      <span class='rbrace token'>}</span><span class='rparen token'>)</span>
+    <span class='end end kw'>end</span>
+  <span class='end end kw'>end</span>
+  <span class='images identifier id'>images</span><span class='dot token'>.</span><span class='sort_by identifier id'>sort_by</span><span class='lbrace token'>{</span><span class='bitor op'>|</span><span class='e identifier id'>e</span><span class='bitor op'>|</span> <span class='lbrack token'>[</span><span class='e identifier id'>e</span><span class='dot token'>.</span><span class='description identifier id'>description</span><span class='rbrack token'>]</span><span class='rbrace token'>}</span>
+  <span class='images identifier id'>images</span> <span class='assign token'>=</span> <span class='filter_on identifier id'>filter_on</span><span class='lparen token'>(</span> <span class='images identifier id'>images</span><span class='comma token'>,</span> <span class='symbol val'>:id</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='rparen token'>)</span>
+  <span class='images identifier id'>images</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="instances-instance_method">
+  
+    - (<tt>Object</tt>) <strong>instances</strong>(credentials, opts = nil) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+74
+75
+76
+77
+78
+79
+80
+81
+82
+83
+84</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 74</span>
+
+<span class='def def kw'>def</span> <span class='instances identifier id'>instances</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='assign token'>=</span><span class='nil nil kw'>nil</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+    <span class='instances identifier id'>instances</span> <span class='assign token'>=</span> <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='list_nodes identifier id'>list_nodes</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span> <span class='inst identifier id'>inst</span> <span class='bitor op'>|</span>
+      <span class='convert_srv_to_instance identifier id'>convert_srv_to_instance</span><span class='lparen token'>(</span><span class='inst identifier id'>inst</span><span class='rparen token'>)</span>
+    <span class='end end kw'>end</span>
+  <span class='end end kw'>end</span>
+  <span class='instances identifier id'>instances</span> <span class='assign token'>=</span> <span class='filter_on identifier id'>filter_on</span><span class='lparen token'>(</span> <span class='instances identifier id'>instances</span><span class='comma token'>,</span> <span class='symbol val'>:id</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='rparen token'>)</span>
+  <span class='instances identifier id'>instances</span> <span class='assign token'>=</span> <span class='filter_on identifier id'>filter_on</span><span class='lparen token'>(</span> <span class='instances identifier id'>instances</span><span class='comma token'>,</span> <span class='symbol val'>:state</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span> <span class='rparen token'>)</span>
+  <span class='instances identifier id'>instances</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="realms-instance_method">
+  
+    - (<tt>Object</tt>) <strong>realms</strong>(credentials, opts = nil) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+66
+67
+68
+69
+70
+71
+72</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 66</span>
+
+<span class='def def kw'>def</span> <span class='realms identifier id'>realms</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='opts identifier id'>opts</span><span class='assign token'>=</span><span class='nil nil kw'>nil</span><span class='rparen token'>)</span>
+  <span class='lbrack token'>[</span><span class='Realm constant id'>Realm</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span> <span class='lbrace token'>{</span>
+          <span class='symbol val'>:id=</span><span class='gt op'>&gt;</span><span class='string val'>&quot;rimu&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:name=</span><span class='gt op'>&gt;</span><span class='string val'>&quot;RimuHosting&quot;</span><span class='comma token'>,</span>
+          <span class='symbol val'>:state=</span><span class='gt op'>&gt;</span> <span class='string val'>&quot;AVAILABLE&quot;</span>
+  <span class='rbrace token'>}</span> <span class='rparen token'>)</span><span class='rbrack token'>]</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="reboot_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>reboot_instance</strong>(credentials, id) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+86
+87
+88
+89
+90
+91</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 86</span>
+
+<span class='def def kw'>def</span> <span class='reboot_instance identifier id'>reboot_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+    <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='set_server_state identifier id'>set_server_state</span><span class='lparen token'>(</span><span class='id identifier id'>id</span><span class='comma token'>,</span> <span class='symbol val'>:RESTARTING</span><span class='rparen token'>)</span>
+  <span class='end end kw'>end</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="safely-instance_method">
+  
+    - (<tt>Object</tt>) <strong>safely</strong>(&amp;block) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+153
+154
+155
+156
+157
+158
+159</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 153</span>
+
+<span class='def def kw'>def</span> <span class='safely identifier id'>safely</span><span class='lparen token'>(</span><span class='bitand op'>&amp;</span><span class='block identifier id'>block</span><span class='rparen token'>)</span>
+  <span class='begin begin kw'>begin</span>
+    <span class='block identifier id'>block</span><span class='dot token'>.</span><span class='call identifier id'>call</span>
+  <span class='rescue rescue kw'>rescue</span> <span class='Exception constant id'>Exception</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='e identifier id'>e</span>
+    <span class='raise identifier id'>raise</span> <span class='Deltacloud constant id'>Deltacloud</span><span class='colon2 op'>::</span><span class='BackendError constant id'>BackendError</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='integer val'>500</span><span class='comma token'>,</span> <span class='e identifier id'>e</span><span class='dot token'>.</span><span class='class identifier id'>class</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='comma token'>,</span> <span class='e identifier id'>e</span><span class='dot token'>.</span><span class='message identifier id'>message</span><span class='comma token'>,</span> <span class='e identifier id'>e</span><span class='dot token'>.</span><span class='backtrace identifier id'>backtrace</span><span class='rparen token'>)</span>
+  <span class='end end kw'>end</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="start_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>start_instance</strong>(credentials, id) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+93
+94
+95
+96
+97
+98</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 93</span>
+
+<span class='def def kw'>def</span> <span class='start_instance identifier id'>start_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='safely identifier id'>safely</span> <span class='do do kw'>do</span>
+    <span class='rh identifier id'>rh</span> <span class='assign token'>=</span> <span class='RimuHostingClient constant id'>RimuHostingClient</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='rparen token'>)</span>
+    <span class='rh identifier id'>rh</span><span class='dot token'>.</span><span class='set_server_state identifier id'>set_server_state</span><span class='lparen token'>(</span><span class='id identifier id'>id</span><span class='comma token'>,</span> <span class='symbol val'>:STARTED</span><span class='rparen token'>)</span>
+  <span class='end end kw'>end</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+      <div class="method_details ">
+  <p class="signature " id="stop_instance-instance_method">
+  
+    - (<tt>Object</tt>) <strong>stop_instance</strong>(credentials, id) 
+  
+
+  
+</p><table class="source_code">
+  <tr>
+    <td>
+      <pre class="lines">
+
+
+100
+101
+102</pre>
+    </td>
+    <td>
+      <pre class="code"><span class="info file"># File 'lib/deltacloud/drivers/rimuhosting/rimuhosting_driver.rb', line 100</span>
+
+<span class='def def kw'>def</span> <span class='stop_instance identifier id'>stop_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='id identifier id'>id</span><span class='rparen token'>)</span>
+  <span class='destroy_instance identifier id'>destroy_instance</span><span class='lparen token'>(</span><span class='credentials identifier id'>credentials</span><span class='comma token'>,</span> <span class='id identifier id'>id</span><span class='rparen token'>)</span>
+<span class='end end kw'>end</span>
+</pre>
+    </td>
+  </tr>
+</table>
+</div>
+    
+  </div>
+
+</div>
+    
+    <div id="footer">
+  Generated on Thu Sep 30 14:44:00 2010 by 
+  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
+  0.6.1 (ruby-1.8.6).
+</div>
+
+  </body>
+</html>
\ No newline at end of file

Added: incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/Terremark.html
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/Terremark.html?rev=1003045&view=auto
==============================================================================
--- incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/Terremark.html (added)
+++ incubator/deltacloud/trunk/site/api-docs/Deltacloud/Drivers/Terremark.html Thu Sep 30 12:48:00 2010
@@ -0,0 +1,91 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+  <head>
+    <meta name="Content-Type" content="text/html; charset=utf8" />
+<title>Module: Deltacloud::Drivers::Terremark</title>
+<link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
+<link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
+
+<script type="text/javascript" charset="utf-8">
+  relpath = '../..';
+  if (relpath != '') relpath += '/';
+</script>
+<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
+<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
+
+  </head>
+  <body>
+    <script type="text/javascript" charset="utf-8">
+      if (window.top.frames.main) document.body.className = 'frames';
+    </script>
+    
+    <div id="header">
+      <div id="menu">
+  
+    <a href="../../_index.html">Index (T)</a> &raquo; 
+    <span class='title'><span class='object_link'><a href="../../Deltacloud.html" title="Deltacloud (module)">Deltacloud</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Drivers.html" title="Deltacloud::Drivers (module)">Drivers</a></span></span>
+     &raquo; 
+    <span class="title">Terremark</span>
+  
+  
+  <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
+</div>
+
+      <div id="search">
+  <a id="class_list_link" href="#">Class List</a>
+  <a id="method_list_link" href="#">Method List</a>
+  <a id ="file_list_link" href="#">File List</a>
+</div>
+
+      <div class="clear"></div>
+    </div>
+    
+    <iframe id="search_frame"></iframe>
+    
+    <div id="content"><h1>Module: Deltacloud::Drivers::Terremark
+  
+  
+  
+</h1>
+
+<dl class="box">
+  
+  
+    
+  
+    
+  
+  
+  
+    <dt class="r1 last">Defined in:</dt>
+    <dd class="r1 last">lib/deltacloud/drivers/terremark/terremark_driver.rb</dd>
+  
+</dl>
+<div class="clear"></div>
+
+<h2>Defined Under Namespace</h2>
+<p class="children">
+   
+    
+   
+    
+      <strong class="classes">Classes:</strong> <span class='object_link'><a href="Terremark/TerremarkDriver.html" title="Deltacloud::Drivers::Terremark::TerremarkDriver (class)">TerremarkDriver</a></span>
+    
+  
+</p>
+
+
+
+
+
+</div>
+    
+    <div id="footer">
+  Generated on Thu Sep 30 14:43:55 2010 by 
+  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
+  0.6.1 (ruby-1.8.6).
+</div>
+
+  </body>
+</html>
\ No newline at end of file



Mime
View raw message