myexperiment-rest 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. data/CHANGES +9 -0
  2. data/LICENSE +23 -0
  3. data/README +33 -0
  4. data/Rakefile +45 -0
  5. data/bin/get_workflow_data.rb +31 -0
  6. data/doc/classes/MyExperimentREST.html +113 -0
  7. data/doc/classes/MyExperimentREST/IOData.html +169 -0
  8. data/doc/classes/MyExperimentREST/IOData.src/M000003.html +20 -0
  9. data/doc/classes/MyExperimentREST/ReadWorkflow.html +184 -0
  10. data/doc/classes/MyExperimentREST/ReadWorkflow.src/M000002.html +39 -0
  11. data/doc/classes/MyExperimentREST/ReadWorkflow.src/M000005.html +41 -0
  12. data/doc/classes/MyExperimentREST/TavernaIOData.html +167 -0
  13. data/doc/classes/MyExperimentREST/TavernaIOData.src/M000006.html +20 -0
  14. data/doc/classes/MyExperimentREST/TavernaIOData.src/M000007.html +20 -0
  15. data/doc/classes/MyExperimentREST/TavernaWorkflow.html +209 -0
  16. data/doc/classes/MyExperimentREST/TavernaWorkflow.src/M000005.html +23 -0
  17. data/doc/classes/MyExperimentREST/TavernaWorkflow.src/M000006.html +22 -0
  18. data/doc/classes/MyExperimentREST/Workflow.html +172 -0
  19. data/doc/classes/MyExperimentREST/Workflow.src/M000001.html +21 -0
  20. data/doc/classes/MyExperimentREST/Workflows.html +167 -0
  21. data/doc/classes/MyExperimentREST/Workflows.src/M000004.html +41 -0
  22. data/doc/classes/TestReadWorkflow.html +167 -0
  23. data/doc/classes/TestReadWorkflow.src/M000001.html +18 -0
  24. data/doc/classes/TestReadWorkflow.src/M000002.html +24 -0
  25. data/doc/classes/TestReadWorkflow.src/M000003.html +20 -0
  26. data/doc/classes/TestReadWorkflow.src/M000004.html +20 -0
  27. data/doc/created.rid +1 -0
  28. data/doc/files/bin/get_workflow_data_rb.html +116 -0
  29. data/doc/files/lib/myexperiment-rest/my_experiment_rest_rb.html +110 -0
  30. data/doc/files/lib/myexperiment-rest/myexperiment_rest_rb.html +110 -0
  31. data/doc/files/lib/myexperiment-rest_rb.html +108 -0
  32. data/doc/files/test/test_read_workflow_rb.html +122 -0
  33. data/doc/fr_class_index.html +31 -0
  34. data/doc/fr_file_index.html +29 -0
  35. data/doc/fr_method_index.html +32 -0
  36. data/doc/index.html +24 -0
  37. data/doc/rdoc-style.css +208 -0
  38. data/doc/rdoc/classes/MyExperimentREST.html +117 -0
  39. data/doc/rdoc/classes/MyExperimentREST/TavernaIOData.html +178 -0
  40. data/doc/rdoc/classes/MyExperimentREST/TavernaWorkflow.html +223 -0
  41. data/doc/rdoc/classes/MyExperimentREST/Workflows.html +199 -0
  42. data/doc/rdoc/created.rid +1 -0
  43. data/doc/rdoc/files/CHANGES.html +121 -0
  44. data/doc/rdoc/files/LICENSE.html +133 -0
  45. data/doc/rdoc/files/README.html +148 -0
  46. data/doc/rdoc/files/lib/myexperiment-rest/myexperiment_rest_rb.html +110 -0
  47. data/doc/rdoc/files/lib/myexperiment-rest_rb.html +108 -0
  48. data/doc/rdoc/fr_class_index.html +30 -0
  49. data/doc/rdoc/fr_file_index.html +31 -0
  50. data/doc/rdoc/fr_method_index.html +29 -0
  51. data/doc/rdoc/index.html +24 -0
  52. data/doc/rdoc/rdoc-style.css +208 -0
  53. data/lib/myexperiment-rest.rb +5 -0
  54. data/lib/myexperiment-rest/myexperiment_rest.rb +146 -0
  55. metadata +133 -0
@@ -0,0 +1,199 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>Class: MyExperimentREST::Workflows</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="classHeader">
50
+ <table class="header-table">
51
+ <tr class="top-aligned-row">
52
+ <td><strong>Class</strong></td>
53
+ <td class="class-name-in-header">MyExperimentREST::Workflows</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../files/lib/myexperiment-rest/myexperiment_rest_rb.html">
59
+ lib/myexperiment-rest/myexperiment_rest.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ <tr class="top-aligned-row">
66
+ <td><strong>Parent:</strong></td>
67
+ <td>
68
+ Object
69
+ </td>
70
+ </tr>
71
+ </table>
72
+ </div>
73
+ <!-- banner header -->
74
+
75
+ <div id="bodyContent">
76
+
77
+
78
+
79
+ <div id="contextContent">
80
+
81
+ <div id="description">
82
+ <p>
83
+ Connects to myExperiment REST API and creates a <em><a
84
+ href="TavernaWorkflow.html">TavernaWorkflow</a></em> object.
85
+ </p>
86
+
87
+ </div>
88
+
89
+
90
+ </div>
91
+
92
+ <div id="method-list">
93
+ <h3 class="section-bar">Methods</h3>
94
+
95
+ <div class="name-list">
96
+ <a href="#M000001">read</a>&nbsp;&nbsp;
97
+ </div>
98
+ </div>
99
+
100
+ </div>
101
+
102
+
103
+ <!-- if includes -->
104
+ <div id="includes">
105
+ <h3 class="section-bar">Included Modules</h3>
106
+
107
+ <div id="includes-list">
108
+ <span class="include-name">LibXML</span>
109
+ </div>
110
+ </div>
111
+
112
+ <div id="section">
113
+
114
+
115
+
116
+
117
+
118
+ <div id="attribute-list">
119
+ <h3 class="section-bar">Attributes</h3>
120
+
121
+ <div class="name-list">
122
+ <table>
123
+ <tr class="top-aligned-row context-row">
124
+ <td class="context-item-name">uri</td>
125
+ <td class="context-item-value">&nbsp;[R]&nbsp;</td>
126
+ <td class="context-item-desc"></td>
127
+ </tr>
128
+ </table>
129
+ </div>
130
+ </div>
131
+
132
+
133
+
134
+ <!-- if method_list -->
135
+ <div id="methods">
136
+ <h3 class="section-bar">Public Instance methods</h3>
137
+
138
+ <div id="method-M000001" class="method-detail">
139
+ <a name="M000001"></a>
140
+
141
+ <div class="method-heading">
142
+ <a href="#M000001" class="method-signature">
143
+ <span class="method-name">read</span><span class="method-args">(uri)</span>
144
+ </a>
145
+ </div>
146
+
147
+ <div class="method-description">
148
+ <p>
149
+ Requires the URI of the workflow in the repository as a String.
150
+ </p>
151
+ <p><a class="source-toggle" href="#"
152
+ onclick="toggleCode('M000001-source');return false;">[Source]</a></p>
153
+ <div class="method-source-code" id="M000001-source">
154
+ <pre>
155
+ <span class="ruby-comment cmt"># File lib/myexperiment-rest/myexperiment_rest.rb, line 19</span>
156
+ 19: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">read</span>(<span class="ruby-identifier">uri</span>)
157
+ 20:
158
+ 21: <span class="ruby-identifier">workflow_id</span> = <span class="ruby-value str">''</span>
159
+ 22: <span class="ruby-identifier">workflow_version</span> = <span class="ruby-value str">''</span>
160
+ 23:
161
+ 24: <span class="ruby-comment cmt"># Get workflow id</span>
162
+ 25: <span class="ruby-identifier">uri_id</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp re">/workflows\/(\d+)/</span>)
163
+ 26: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">uri_id</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword kw">nil</span>
164
+ 27: <span class="ruby-identifier">workflow_id</span> = <span class="ruby-identifier">uri_id</span>[<span class="ruby-value">1</span>]
165
+ 28: <span class="ruby-keyword kw">else</span>
166
+ 29: <span class="ruby-identifier">raise</span> <span class="ruby-value str">&quot;Could not match workflow id.&quot;</span>
167
+ 30: <span class="ruby-keyword kw">end</span>
168
+ 31:
169
+ 32: <span class="ruby-comment cmt"># Get workflow version if it exists</span>
170
+ 33: <span class="ruby-identifier">uri_version</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp re">/version=(\d+)/</span>)
171
+ 34: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">uri_version</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword kw">nil</span>
172
+ 35: <span class="ruby-identifier">workflow_version</span> = <span class="ruby-identifier">uri_version</span>[<span class="ruby-value">1</span>]
173
+ 36: <span class="ruby-keyword kw">end</span>
174
+ 37:
175
+ 38: <span class="ruby-comment cmt"># Get workflow resource information -- if version is empty it returns the current version</span>
176
+ 39: <span class="ruby-identifier">response</span> = <span class="ruby-constant">RestClient</span>.<span class="ruby-identifier">get</span>(<span class="ruby-value str">'http://www.myexperiment.org/workflow.xml'</span>, {<span class="ruby-identifier">:params</span> =<span class="ruby-operator">&gt;</span> {<span class="ruby-value str">'id'</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-node">&quot;#{workflow_id}&quot;</span>,
177
+ 40: <span class="ruby-value str">'version'</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-node">&quot;#{workflow_version}&quot;</span>,
178
+ 41: <span class="ruby-value str">'elements'</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value str">'title,description,content-uri,components'</span>} } )
179
+ 42:
180
+ 43: <span class="ruby-identifier">populate_workflow</span>(<span class="ruby-identifier">response</span>)
181
+ 44: <span class="ruby-keyword kw">end</span>
182
+ </pre>
183
+ </div>
184
+ </div>
185
+ </div>
186
+
187
+
188
+ </div>
189
+
190
+
191
+ </div>
192
+
193
+
194
+ <div id="validator-badges">
195
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
196
+ </div>
197
+
198
+ </body>
199
+ </html>
@@ -0,0 +1 @@
1
+ Wed, 20 Jul 2011 19:32:01 +0200
@@ -0,0 +1,121 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>File: CHANGES</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="fileHeader">
50
+ <h1>CHANGES</h1>
51
+ <table class="header-table">
52
+ <tr class="top-aligned-row">
53
+ <td><strong>Path:</strong></td>
54
+ <td>CHANGES
55
+ </td>
56
+ </tr>
57
+ <tr class="top-aligned-row">
58
+ <td><strong>Last Update:</strong></td>
59
+ <td>Wed Jul 20 19:30:21 +0200 2011</td>
60
+ </tr>
61
+ </table>
62
+ </div>
63
+ <!-- banner header -->
64
+
65
+ <div id="bodyContent">
66
+
67
+
68
+
69
+ <div id="contextContent">
70
+
71
+ <div id="description">
72
+ <h1>Changes log for the MyExperiment via REST Gem</h1>
73
+ <h2>Version 0.2.6</h2>
74
+ <ul>
75
+ <li>Added dependency in gem specification.
76
+
77
+ </li>
78
+ </ul>
79
+ <h2>Version 0.2.5</h2>
80
+ <ul>
81
+ <li>Abstracted the TavernaWorkflow class better so that it can be properly
82
+ reused.
83
+
84
+ </li>
85
+ <li>API slightly changed; added input_type ([T2_FLOW | MY_EXPERIMENT])
86
+
87
+ </li>
88
+ </ul>
89
+
90
+ </div>
91
+
92
+
93
+ </div>
94
+
95
+
96
+ </div>
97
+
98
+
99
+ <!-- if includes -->
100
+
101
+ <div id="section">
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+ <!-- if method_list -->
111
+
112
+
113
+ </div>
114
+
115
+
116
+ <div id="validator-badges">
117
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
118
+ </div>
119
+
120
+ </body>
121
+ </html>
@@ -0,0 +1,133 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>File: LICENSE</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="fileHeader">
50
+ <h1>LICENSE</h1>
51
+ <table class="header-table">
52
+ <tr class="top-aligned-row">
53
+ <td><strong>Path:</strong></td>
54
+ <td>LICENSE
55
+ </td>
56
+ </tr>
57
+ <tr class="top-aligned-row">
58
+ <td><strong>Last Update:</strong></td>
59
+ <td>Wed Apr 06 16:45:13 +0200 2011</td>
60
+ </tr>
61
+ </table>
62
+ </div>
63
+ <!-- banner header -->
64
+
65
+ <div id="bodyContent">
66
+
67
+
68
+
69
+ <div id="contextContent">
70
+
71
+ <div id="description">
72
+ <h2>myexperiment-rest</h2>
73
+ <p>
74
+ The MIT License
75
+ </p>
76
+ <p>
77
+ Copyright (c) 2010 - Netherlands Bioinformatics Centre
78
+ </p>
79
+ <p>
80
+ Permission is hereby granted, free of charge, to any person obtaining a
81
+ copy of this software and associated documentation files (the
82
+ &quot;Software&quot;), to deal in the Software without restriction,
83
+ including without limitation the rights to use, copy, modify, merge,
84
+ publish, distribute, sublicense, and/or sell copies of the Software, and to
85
+ permit persons to whom the Software is furnished to do so, subject to the
86
+ following conditions:
87
+ </p>
88
+ <p>
89
+ The above copyright notice and this permission notice shall be included in
90
+ all copies or substantial portions of the Software.
91
+ </p>
92
+ <p>
93
+ THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND,
94
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
95
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
96
+ NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
97
+ DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
98
+ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
99
+ USE OR OTHER DEALINGS IN THE SOFTWARE.
100
+ </p>
101
+
102
+ </div>
103
+
104
+
105
+ </div>
106
+
107
+
108
+ </div>
109
+
110
+
111
+ <!-- if includes -->
112
+
113
+ <div id="section">
114
+
115
+
116
+
117
+
118
+
119
+
120
+
121
+
122
+ <!-- if method_list -->
123
+
124
+
125
+ </div>
126
+
127
+
128
+ <div id="validator-badges">
129
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
130
+ </div>
131
+
132
+ </body>
133
+ </html>