appscale-tools 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (114) hide show
  1. data/LICENSE +37 -0
  2. data/README +17 -0
  3. data/bin/appscale-add-keypair +15 -0
  4. data/bin/appscale-describe-instances +16 -0
  5. data/bin/appscale-remove-app +13 -0
  6. data/bin/appscale-reset-pwd +13 -0
  7. data/bin/appscale-run-instances +15 -0
  8. data/bin/appscale-terminate-instances +14 -0
  9. data/bin/appscale-upload-app +13 -0
  10. data/doc/AdvancedNode.html +163 -0
  11. data/doc/AppControllerClient.html +831 -0
  12. data/doc/AppEngineConfigException.html +165 -0
  13. data/doc/AppScaleException.html +165 -0
  14. data/doc/AppScaleTools.html +768 -0
  15. data/doc/BadCommandLineArgException.html +166 -0
  16. data/doc/BadConfigurationException.html +166 -0
  17. data/doc/CommonFunctions.html +2559 -0
  18. data/doc/EncryptionHelper.html +332 -0
  19. data/doc/GodInterface.html +443 -0
  20. data/doc/InfrastructureException.html +166 -0
  21. data/doc/Node.html +470 -0
  22. data/doc/NodeLayout.html +1297 -0
  23. data/doc/Object.html +539 -0
  24. data/doc/ParseArgs.html +268 -0
  25. data/doc/RemoteLogging.html +268 -0
  26. data/doc/SimpleNode.html +163 -0
  27. data/doc/UsageText.html +1204 -0
  28. data/doc/UserAppClient.html +993 -0
  29. data/doc/VMTools.html +1365 -0
  30. data/doc/bin/appscale-add-keypair.html +56 -0
  31. data/doc/bin/appscale-describe-instances.html +56 -0
  32. data/doc/bin/appscale-remove-app.html +56 -0
  33. data/doc/bin/appscale-reset-pwd.html +56 -0
  34. data/doc/bin/appscale-run-instances.html +56 -0
  35. data/doc/bin/appscale-terminate-instances.html +56 -0
  36. data/doc/bin/appscale-upload-app.html +56 -0
  37. data/doc/created.rid +21 -0
  38. data/doc/images/add.png +0 -0
  39. data/doc/images/brick.png +0 -0
  40. data/doc/images/brick_link.png +0 -0
  41. data/doc/images/bug.png +0 -0
  42. data/doc/images/bullet_black.png +0 -0
  43. data/doc/images/bullet_toggle_minus.png +0 -0
  44. data/doc/images/bullet_toggle_plus.png +0 -0
  45. data/doc/images/date.png +0 -0
  46. data/doc/images/delete.png +0 -0
  47. data/doc/images/find.png +0 -0
  48. data/doc/images/loadingAnimation.gif +0 -0
  49. data/doc/images/macFFBgHack.png +0 -0
  50. data/doc/images/package.png +0 -0
  51. data/doc/images/page_green.png +0 -0
  52. data/doc/images/page_white_text.png +0 -0
  53. data/doc/images/page_white_width.png +0 -0
  54. data/doc/images/plugin.png +0 -0
  55. data/doc/images/ruby.png +0 -0
  56. data/doc/images/tag_blue.png +0 -0
  57. data/doc/images/tag_green.png +0 -0
  58. data/doc/images/transparent.png +0 -0
  59. data/doc/images/wrench.png +0 -0
  60. data/doc/images/wrench_orange.png +0 -0
  61. data/doc/images/zoom.png +0 -0
  62. data/doc/index.html +116 -0
  63. data/doc/js/darkfish.js +153 -0
  64. data/doc/js/jquery.js +18 -0
  65. data/doc/js/navigation.js +142 -0
  66. data/doc/js/quicksearch.js +114 -0
  67. data/doc/js/search.js +94 -0
  68. data/doc/js/search_index.js +1 -0
  69. data/doc/js/searcher.js +228 -0
  70. data/doc/js/thickbox-compressed.js +10 -0
  71. data/doc/lib/app_controller_client_rb.html +60 -0
  72. data/doc/lib/appscale_tools_rb.html +88 -0
  73. data/doc/lib/common_functions_rb.html +78 -0
  74. data/doc/lib/custom_exceptions_rb.html +54 -0
  75. data/doc/lib/encryption_helper_rb.html +60 -0
  76. data/doc/lib/godinterface_rb.html +52 -0
  77. data/doc/lib/node_layout_rb.html +55 -0
  78. data/doc/lib/parse_args_rb.html +58 -0
  79. data/doc/lib/remote_log_rb.html +58 -0
  80. data/doc/lib/sshcopyid.html +174 -0
  81. data/doc/lib/usage_text_rb.html +58 -0
  82. data/doc/lib/user_app_client_rb.html +62 -0
  83. data/doc/lib/vm_tools_rb.html +62 -0
  84. data/doc/table_of_contents.html +496 -0
  85. data/lib/app_controller_client.rb +181 -0
  86. data/lib/appscale_tools.rb +403 -0
  87. data/lib/common_functions.rb +1467 -0
  88. data/lib/custom_exceptions.rb +25 -0
  89. data/lib/encryption_helper.rb +86 -0
  90. data/lib/godinterface.rb +152 -0
  91. data/lib/node_layout.rb +665 -0
  92. data/lib/parse_args.rb +415 -0
  93. data/lib/remote_log.rb +46 -0
  94. data/lib/sshcopyid +65 -0
  95. data/lib/usage_text.rb +144 -0
  96. data/lib/user_app_client.rb +245 -0
  97. data/lib/vm_tools.rb +549 -0
  98. data/test/tc_app_controller_client.rb +10 -0
  99. data/test/tc_appscale_add_keypair.rb +44 -0
  100. data/test/tc_appscale_describe_instances.rb +69 -0
  101. data/test/tc_appscale_remove_app.rb +128 -0
  102. data/test/tc_appscale_reset_pwd.rb +156 -0
  103. data/test/tc_appscale_run_instances.rb +48 -0
  104. data/test/tc_appscale_terminate_instances.rb +104 -0
  105. data/test/tc_appscale_upload_app.rb +166 -0
  106. data/test/tc_common_functions.rb +56 -0
  107. data/test/tc_encryption_helper.rb +10 -0
  108. data/test/tc_god_interface.rb +10 -0
  109. data/test/tc_node_layout.rb +93 -0
  110. data/test/tc_parse_args.rb +160 -0
  111. data/test/tc_user_app_client.rb +10 -0
  112. data/test/tc_vm_tools.rb +10 -0
  113. data/test/ts_all.rb +20 -0
  114. metadata +211 -0
@@ -0,0 +1,166 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
6
+
7
+ <title>class InfrastructureException - RDoc Documentation</title>
8
+
9
+ <link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet">
10
+
11
+ <script type="text/javascript">
12
+ var rdoc_rel_prefix = "./";
13
+ </script>
14
+
15
+ <script type="text/javascript" charset="utf-8" src="./js/jquery.js"></script>
16
+ <script type="text/javascript" charset="utf-8" src="./js/navigation.js"></script>
17
+ <script type="text/javascript" charset="utf-8" src="./js/search_index.js"></script>
18
+ <script type="text/javascript" charset="utf-8" src="./js/search.js"></script>
19
+ <script type="text/javascript" charset="utf-8" src="./js/searcher.js"></script>
20
+ <script type="text/javascript" charset="utf-8" src="./js/darkfish.js"></script>
21
+
22
+
23
+ <body id="top" class="class">
24
+ <nav id="metadata">
25
+ <nav id="home-section" class="section">
26
+ <h3 class="section-header">
27
+ <a href="./index.html">Home</a>
28
+ <a href="./table_of_contents.html#classes">Classes</a>
29
+ <a href="./table_of_contents.html#methods">Methods</a>
30
+ </h3>
31
+ </nav>
32
+
33
+
34
+ <nav id="search-section" class="section project-section" class="initially-hidden">
35
+ <form action="#" method="get" accept-charset="utf-8">
36
+ <h3 class="section-header">
37
+ <input type="text" name="search" placeholder="Search" id="search-field"
38
+ title="Type to search, Up and Down to navigate, Enter to load">
39
+ </h3>
40
+ </form>
41
+
42
+ <ul id="search-results" class="initially-hidden"></ul>
43
+ </nav>
44
+
45
+
46
+ <div id="file-metadata">
47
+ <nav id="file-list-section" class="section">
48
+ <h3 class="section-header">Defined In</h3>
49
+ <ul>
50
+ <li>lib/custom_exceptions.rb
51
+ </ul>
52
+ </nav>
53
+
54
+
55
+ </div>
56
+
57
+ <div id="class-metadata">
58
+
59
+ <nav id="parent-class-section" class="section">
60
+ <h3 class="section-header">Parent</h3>
61
+
62
+ <p class="link"><a href="AppScaleException.html">AppScaleException</a>
63
+
64
+ </nav>
65
+
66
+
67
+
68
+ </div>
69
+
70
+ <div id="project-metadata">
71
+ <nav id="fileindex-section" class="section project-section">
72
+ <h3 class="section-header">Pages</h3>
73
+
74
+ <ul>
75
+
76
+ <li class="file"><a href="./lib/sshcopyid.html">sshcopyid</a>
77
+
78
+ </ul>
79
+ </nav>
80
+
81
+ <nav id="classindex-section" class="section project-section">
82
+ <h3 class="section-header">Class and Module Index</h3>
83
+
84
+ <ul class="link-list">
85
+
86
+ <li><a href="./AdvancedNode.html">AdvancedNode</a>
87
+
88
+ <li><a href="./AppControllerClient.html">AppControllerClient</a>
89
+
90
+ <li><a href="./AppEngineConfigException.html">AppEngineConfigException</a>
91
+
92
+ <li><a href="./AppScaleException.html">AppScaleException</a>
93
+
94
+ <li><a href="./AppScaleTools.html">AppScaleTools</a>
95
+
96
+ <li><a href="./BadCommandLineArgException.html">BadCommandLineArgException</a>
97
+
98
+ <li><a href="./BadConfigurationException.html">BadConfigurationException</a>
99
+
100
+ <li><a href="./CommonFunctions.html">CommonFunctions</a>
101
+
102
+ <li><a href="./EncryptionHelper.html">EncryptionHelper</a>
103
+
104
+ <li><a href="./GodInterface.html">GodInterface</a>
105
+
106
+ <li><a href="./InfrastructureException.html">InfrastructureException</a>
107
+
108
+ <li><a href="./Node.html">Node</a>
109
+
110
+ <li><a href="./NodeLayout.html">NodeLayout</a>
111
+
112
+ <li><a href="./Object.html">Object</a>
113
+
114
+ <li><a href="./ParseArgs.html">ParseArgs</a>
115
+
116
+ <li><a href="./RemoteLogging.html">RemoteLogging</a>
117
+
118
+ <li><a href="./SimpleNode.html">SimpleNode</a>
119
+
120
+ <li><a href="./UsageText.html">UsageText</a>
121
+
122
+ <li><a href="./UserAppClient.html">UserAppClient</a>
123
+
124
+ <li><a href="./VMTools.html">VMTools</a>
125
+
126
+ </ul>
127
+ </nav>
128
+
129
+ </div>
130
+ </nav>
131
+
132
+ <div id="documentation">
133
+ <h1 class="class">class InfrastructureException</h1>
134
+
135
+ <div id="description" class="description">
136
+
137
+ <p>a class representing exceptions related to cloud infrastructures (e.g., if
138
+ euca or ec2 throw errors)</p>
139
+
140
+ </div><!-- description -->
141
+
142
+
143
+
144
+
145
+ <section id="5Buntitled-5D" class="documentation-section">
146
+
147
+
148
+
149
+
150
+
151
+
152
+
153
+
154
+ <!-- Methods -->
155
+
156
+ </section><!-- 5Buntitled-5D -->
157
+
158
+ </div><!-- documentation -->
159
+
160
+
161
+ <footer id="validator-badges">
162
+ <p><a href="http://validator.w3.org/check/referer">[Validate]</a>
163
+ <p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.
164
+ <p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
165
+ </footer>
166
+
data/doc/Node.html ADDED
@@ -0,0 +1,470 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
6
+
7
+ <title>class Node - RDoc Documentation</title>
8
+
9
+ <link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet">
10
+
11
+ <script type="text/javascript">
12
+ var rdoc_rel_prefix = "./";
13
+ </script>
14
+
15
+ <script type="text/javascript" charset="utf-8" src="./js/jquery.js"></script>
16
+ <script type="text/javascript" charset="utf-8" src="./js/navigation.js"></script>
17
+ <script type="text/javascript" charset="utf-8" src="./js/search_index.js"></script>
18
+ <script type="text/javascript" charset="utf-8" src="./js/search.js"></script>
19
+ <script type="text/javascript" charset="utf-8" src="./js/searcher.js"></script>
20
+ <script type="text/javascript" charset="utf-8" src="./js/darkfish.js"></script>
21
+
22
+
23
+ <body id="top" class="class">
24
+ <nav id="metadata">
25
+ <nav id="home-section" class="section">
26
+ <h3 class="section-header">
27
+ <a href="./index.html">Home</a>
28
+ <a href="./table_of_contents.html#classes">Classes</a>
29
+ <a href="./table_of_contents.html#methods">Methods</a>
30
+ </h3>
31
+ </nav>
32
+
33
+
34
+ <nav id="search-section" class="section project-section" class="initially-hidden">
35
+ <form action="#" method="get" accept-charset="utf-8">
36
+ <h3 class="section-header">
37
+ <input type="text" name="search" placeholder="Search" id="search-field"
38
+ title="Type to search, Up and Down to navigate, Enter to load">
39
+ </h3>
40
+ </form>
41
+
42
+ <ul id="search-results" class="initially-hidden"></ul>
43
+ </nav>
44
+
45
+
46
+ <div id="file-metadata">
47
+ <nav id="file-list-section" class="section">
48
+ <h3 class="section-header">Defined In</h3>
49
+ <ul>
50
+ <li>lib/node_layout.rb
51
+ </ul>
52
+ </nav>
53
+
54
+
55
+ </div>
56
+
57
+ <div id="class-metadata">
58
+
59
+ <nav id="parent-class-section" class="section">
60
+ <h3 class="section-header">Parent</h3>
61
+
62
+ <p class="link"><a href="Object.html">Object</a>
63
+
64
+ </nav>
65
+
66
+
67
+ <!-- Method Quickref -->
68
+ <nav id="method-list-section" class="section">
69
+ <h3 class="section-header">Methods</h3>
70
+
71
+ <ul class="link-list">
72
+
73
+ <li><a href="#method-c-new">::new</a>
74
+
75
+ <li><a href="#method-i-add_db_role">#add_db_role</a>
76
+
77
+ <li><a href="#method-i-add_rabbitmq_role">#add_rabbitmq_role</a>
78
+
79
+ <li><a href="#method-i-add_role">#add_role</a>
80
+
81
+ <li><a href="#method-i-errors">#errors</a>
82
+
83
+ <li><a href="#method-i-expand_roles">#expand_roles</a>
84
+
85
+ <li><a href="#method-i-valid-3F">#valid?</a>
86
+
87
+ </ul>
88
+ </nav>
89
+
90
+ </div>
91
+
92
+ <div id="project-metadata">
93
+ <nav id="fileindex-section" class="section project-section">
94
+ <h3 class="section-header">Pages</h3>
95
+
96
+ <ul>
97
+
98
+ <li class="file"><a href="./lib/sshcopyid.html">sshcopyid</a>
99
+
100
+ </ul>
101
+ </nav>
102
+
103
+ <nav id="classindex-section" class="section project-section">
104
+ <h3 class="section-header">Class and Module Index</h3>
105
+
106
+ <ul class="link-list">
107
+
108
+ <li><a href="./AdvancedNode.html">AdvancedNode</a>
109
+
110
+ <li><a href="./AppControllerClient.html">AppControllerClient</a>
111
+
112
+ <li><a href="./AppEngineConfigException.html">AppEngineConfigException</a>
113
+
114
+ <li><a href="./AppScaleException.html">AppScaleException</a>
115
+
116
+ <li><a href="./AppScaleTools.html">AppScaleTools</a>
117
+
118
+ <li><a href="./BadCommandLineArgException.html">BadCommandLineArgException</a>
119
+
120
+ <li><a href="./BadConfigurationException.html">BadConfigurationException</a>
121
+
122
+ <li><a href="./CommonFunctions.html">CommonFunctions</a>
123
+
124
+ <li><a href="./EncryptionHelper.html">EncryptionHelper</a>
125
+
126
+ <li><a href="./GodInterface.html">GodInterface</a>
127
+
128
+ <li><a href="./InfrastructureException.html">InfrastructureException</a>
129
+
130
+ <li><a href="./Node.html">Node</a>
131
+
132
+ <li><a href="./NodeLayout.html">NodeLayout</a>
133
+
134
+ <li><a href="./Object.html">Object</a>
135
+
136
+ <li><a href="./ParseArgs.html">ParseArgs</a>
137
+
138
+ <li><a href="./RemoteLogging.html">RemoteLogging</a>
139
+
140
+ <li><a href="./SimpleNode.html">SimpleNode</a>
141
+
142
+ <li><a href="./UsageText.html">UsageText</a>
143
+
144
+ <li><a href="./UserAppClient.html">UserAppClient</a>
145
+
146
+ <li><a href="./VMTools.html">VMTools</a>
147
+
148
+ </ul>
149
+ </nav>
150
+
151
+ </div>
152
+ </nav>
153
+
154
+ <div id="documentation">
155
+ <h1 class="class">class Node</h1>
156
+
157
+ <div id="description" class="description">
158
+
159
+ </div><!-- description -->
160
+
161
+
162
+
163
+
164
+ <section id="5Buntitled-5D" class="documentation-section">
165
+
166
+
167
+
168
+
169
+
170
+
171
+
172
+ <!-- Attributes -->
173
+ <section id="attribute-method-details" class="method-section section">
174
+ <h3 class="section-header">Attributes</h3>
175
+
176
+
177
+ <div id="attribute-i-cloud" class="method-detail">
178
+ <div class="method-heading attribute-method-heading">
179
+ <span class="method-name">cloud</span><span
180
+ class="attribute-access-type">[RW]</span>
181
+ </div>
182
+
183
+ <div class="method-description">
184
+
185
+
186
+
187
+ </div>
188
+ </div>
189
+
190
+ <div id="attribute-i-id" class="method-detail">
191
+ <div class="method-heading attribute-method-heading">
192
+ <span class="method-name">id</span><span
193
+ class="attribute-access-type">[RW]</span>
194
+ </div>
195
+
196
+ <div class="method-description">
197
+
198
+
199
+
200
+ </div>
201
+ </div>
202
+
203
+ <div id="attribute-i-roles" class="method-detail">
204
+ <div class="method-heading attribute-method-heading">
205
+ <span class="method-name">roles</span><span
206
+ class="attribute-access-type">[RW]</span>
207
+ </div>
208
+
209
+ <div class="method-description">
210
+
211
+
212
+
213
+ </div>
214
+ </div>
215
+
216
+ </section><!-- attribute-method-details -->
217
+
218
+
219
+ <!-- Methods -->
220
+
221
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section section">
222
+ <h3 class="section-header">Public Instance Methods</h3>
223
+
224
+
225
+ <div id="method-i-add_db_role" class="method-detail ">
226
+
227
+ <div class="method-heading">
228
+ <span class="method-name">add_db_role</span><span
229
+ class="method-args">(db_type, is_master)</span>
230
+ <span class="method-click-advice">click to toggle source</span>
231
+ </div>
232
+
233
+
234
+ <div class="method-description">
235
+
236
+
237
+
238
+
239
+
240
+ <div class="method-source-code" id="add_db_role-source">
241
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 566</span>
242
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">add_db_role</span> <span class="ruby-identifier">db_type</span>, <span class="ruby-identifier">is_master</span>
243
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">is_master</span>
244
+ <span class="ruby-identifier">add_role</span> <span class="ruby-value">:db_master</span>
245
+ <span class="ruby-identifier">add_role</span> <span class="ruby-value">:zookeeper</span>
246
+ <span class="ruby-keyword">else</span>
247
+ <span class="ruby-identifier">add_role</span> <span class="ruby-value">:db_slave</span>
248
+ <span class="ruby-keyword">end</span>
249
+ <span class="ruby-keyword">end</span></pre>
250
+ </div><!-- add_db_role-source -->
251
+
252
+ </div>
253
+
254
+
255
+
256
+
257
+ </div><!-- add_db_role-method -->
258
+
259
+
260
+ <div id="method-i-add_rabbitmq_role" class="method-detail ">
261
+
262
+ <div class="method-heading">
263
+ <span class="method-name">add_rabbitmq_role</span><span
264
+ class="method-args">(is_master)</span>
265
+ <span class="method-click-advice">click to toggle source</span>
266
+ </div>
267
+
268
+
269
+ <div class="method-description">
270
+
271
+
272
+
273
+
274
+
275
+ <div class="method-source-code" id="add_rabbitmq_role-source">
276
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 575</span>
277
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">add_rabbitmq_role</span> <span class="ruby-identifier">is_master</span>
278
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">is_master</span>
279
+ <span class="ruby-identifier">add_role</span> <span class="ruby-value">:rabbitmq_master</span>
280
+ <span class="ruby-keyword">else</span>
281
+ <span class="ruby-identifier">add_role</span> <span class="ruby-value">:rabbitmq_slave</span>
282
+ <span class="ruby-keyword">end</span>
283
+ <span class="ruby-keyword">end</span></pre>
284
+ </div><!-- add_rabbitmq_role-source -->
285
+
286
+ </div>
287
+
288
+
289
+
290
+
291
+ </div><!-- add_rabbitmq_role-method -->
292
+
293
+
294
+ <div id="method-i-add_role" class="method-detail ">
295
+
296
+ <div class="method-heading">
297
+ <span class="method-name">add_role</span><span
298
+ class="method-args">(role)</span>
299
+ <span class="method-click-advice">click to toggle source</span>
300
+ </div>
301
+
302
+
303
+ <div class="method-description">
304
+
305
+
306
+
307
+
308
+
309
+ <div class="method-source-code" id="add_role-source">
310
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 583</span>
311
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">add_role</span> <span class="ruby-identifier">role</span>
312
+ <span class="ruby-ivar">@roles</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">role</span>.<span class="ruby-identifier">to_sym</span>
313
+ <span class="ruby-identifier">expand_roles</span>
314
+ <span class="ruby-keyword">end</span></pre>
315
+ </div><!-- add_role-source -->
316
+
317
+ </div>
318
+
319
+
320
+
321
+
322
+ </div><!-- add_role-method -->
323
+
324
+
325
+ <div id="method-i-errors" class="method-detail ">
326
+
327
+ <div class="method-heading">
328
+ <span class="method-name">errors</span><span
329
+ class="method-args">()</span>
330
+ <span class="method-click-advice">click to toggle source</span>
331
+ </div>
332
+
333
+
334
+ <div class="method-description">
335
+
336
+
337
+
338
+
339
+
340
+ <div class="method-source-code" id="errors-source">
341
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 599</span>
342
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">errors</span>
343
+ <span class="ruby-ivar">@roles</span>.<span class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">r</span><span class="ruby-operator">|</span> <span class="ruby-node">&quot;Invalid role: #{r}&quot;</span> <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-constant">VALID_ROLES</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">r</span>) }.<span class="ruby-identifier">compact</span>
344
+ <span class="ruby-keyword">end</span></pre>
345
+ </div><!-- errors-source -->
346
+
347
+ </div>
348
+
349
+
350
+
351
+
352
+ </div><!-- errors-method -->
353
+
354
+
355
+ <div id="method-i-expand_roles" class="method-detail ">
356
+
357
+ <div class="method-heading">
358
+ <span class="method-name">expand_roles</span><span
359
+ class="method-args">()</span>
360
+ <span class="method-click-advice">click to toggle source</span>
361
+ </div>
362
+
363
+
364
+ <div class="method-description">
365
+
366
+
367
+
368
+
369
+
370
+ <div class="method-source-code" id="expand_roles-source">
371
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 603</span>
372
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">expand_roles</span>
373
+ <span class="ruby-identifier">error_msg</span> = <span class="ruby-string">&quot;Expand roles should never be called on a node type.&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot; All nodes should be either a SimpleNode or AdvancedNode&quot;</span>
374
+ <span class="ruby-identifier">raise</span> <span class="ruby-constant">RuntimeError</span> <span class="ruby-identifier">error_msg</span>
375
+ <span class="ruby-keyword">end</span></pre>
376
+ </div><!-- expand_roles-source -->
377
+
378
+ </div>
379
+
380
+
381
+
382
+
383
+ </div><!-- expand_roles-method -->
384
+
385
+
386
+ <div id="method-i-valid-3F" class="method-detail ">
387
+
388
+ <div class="method-heading">
389
+ <span class="method-name">valid?</span><span
390
+ class="method-args">()</span>
391
+ <span class="method-click-advice">click to toggle source</span>
392
+ </div>
393
+
394
+
395
+ <div class="method-description">
396
+
397
+
398
+
399
+
400
+
401
+ <div class="method-source-code" id="valid-3F-source">
402
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 595</span>
403
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">valid?</span>
404
+ <span class="ruby-keyword">self</span>.<span class="ruby-identifier">errors</span>.<span class="ruby-identifier">empty?</span>
405
+ <span class="ruby-keyword">end</span></pre>
406
+ </div><!-- valid-3F-source -->
407
+
408
+ </div>
409
+
410
+
411
+
412
+
413
+ </div><!-- valid-3F-method -->
414
+
415
+
416
+ </section><!-- public-instance-method-details -->
417
+
418
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section section">
419
+ <h3 class="section-header">Public Class Methods</h3>
420
+
421
+
422
+ <div id="method-c-new" class="method-detail ">
423
+
424
+ <div class="method-heading">
425
+ <span class="method-name">new</span><span
426
+ class="method-args">(id, cloud, roles=[])</span>
427
+ <span class="method-click-advice">click to toggle source</span>
428
+ </div>
429
+
430
+
431
+ <div class="method-description">
432
+
433
+
434
+
435
+
436
+
437
+ <div class="method-source-code" id="new-source">
438
+ <pre><span class="ruby-comment"># File lib/node_layout.rb, line 556</span>
439
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span> <span class="ruby-identifier">id</span>, <span class="ruby-identifier">cloud</span>, <span class="ruby-identifier">roles</span>=[]
440
+ <span class="ruby-comment"># For Xen/KVM id is the public ip address</span>
441
+ <span class="ruby-comment"># For clouds, id is node-X since the ip is not known</span>
442
+ <span class="ruby-ivar">@id</span> = <span class="ruby-identifier">id</span>
443
+ <span class="ruby-ivar">@cloud</span> = <span class="ruby-identifier">cloud</span>
444
+ <span class="ruby-ivar">@roles</span> = <span class="ruby-identifier">roles</span>.<span class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">r</span><span class="ruby-operator">|</span> <span class="ruby-identifier">r</span>.<span class="ruby-identifier">to_sym</span> }
445
+
446
+ <span class="ruby-identifier">expand_roles</span>
447
+ <span class="ruby-keyword">end</span></pre>
448
+ </div><!-- new-source -->
449
+
450
+ </div>
451
+
452
+
453
+
454
+
455
+ </div><!-- new-method -->
456
+
457
+
458
+ </section><!-- public-class-method-details -->
459
+
460
+ </section><!-- 5Buntitled-5D -->
461
+
462
+ </div><!-- documentation -->
463
+
464
+
465
+ <footer id="validator-badges">
466
+ <p><a href="http://validator.w3.org/check/referer">[Validate]</a>
467
+ <p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.
468
+ <p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
469
+ </footer>
470
+