myexperiment-rest 0.3.3 → 0.3.4
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +4 -1
- data/README +2 -2
- data/Rakefile +3 -3
- metadata +7 -50
- data/doc/rdoc/CHANGES.html +0 -168
- data/doc/rdoc/LICENSE.html +0 -127
- data/doc/rdoc/MyExperimentREST.html +0 -271
- data/doc/rdoc/MyExperimentREST/MyExperimentIOData.html +0 -319
- data/doc/rdoc/MyExperimentREST/MyExperimentUser.html +0 -405
- data/doc/rdoc/MyExperimentREST/MyExperimentWorkflow.html +0 -369
- data/doc/rdoc/MyExperimentREST/SessionCookie.html +0 -216
- data/doc/rdoc/MyExperimentREST/Urls.html +0 -175
- data/doc/rdoc/MyExperimentREST/User.html +0 -262
- data/doc/rdoc/MyExperimentREST/Workflow.html +0 -271
- data/doc/rdoc/README.html +0 -145
- data/doc/rdoc/created.rid +0 -9
- data/doc/rdoc/images/brick.png +0 -0
- data/doc/rdoc/images/brick_link.png +0 -0
- data/doc/rdoc/images/bug.png +0 -0
- data/doc/rdoc/images/bullet_black.png +0 -0
- data/doc/rdoc/images/bullet_toggle_minus.png +0 -0
- data/doc/rdoc/images/bullet_toggle_plus.png +0 -0
- data/doc/rdoc/images/date.png +0 -0
- data/doc/rdoc/images/find.png +0 -0
- data/doc/rdoc/images/loadingAnimation.gif +0 -0
- data/doc/rdoc/images/macFFBgHack.png +0 -0
- data/doc/rdoc/images/package.png +0 -0
- data/doc/rdoc/images/page_green.png +0 -0
- data/doc/rdoc/images/page_white_text.png +0 -0
- data/doc/rdoc/images/page_white_width.png +0 -0
- data/doc/rdoc/images/plugin.png +0 -0
- data/doc/rdoc/images/ruby.png +0 -0
- data/doc/rdoc/images/tag_green.png +0 -0
- data/doc/rdoc/images/wrench.png +0 -0
- data/doc/rdoc/images/wrench_orange.png +0 -0
- data/doc/rdoc/images/zoom.png +0 -0
- data/doc/rdoc/index.html +0 -142
- data/doc/rdoc/js/darkfish.js +0 -116
- data/doc/rdoc/js/jquery.js +0 -32
- data/doc/rdoc/js/quicksearch.js +0 -114
- data/doc/rdoc/js/thickbox-compressed.js +0 -10
- data/doc/rdoc/lib/myexperiment-rest/authentication_rb.html +0 -54
- data/doc/rdoc/lib/myexperiment-rest/constants_rb.html +0 -52
- data/doc/rdoc/lib/myexperiment-rest/user_rb.html +0 -54
- data/doc/rdoc/lib/myexperiment-rest/workflow_rb.html +0 -54
- data/doc/rdoc/lib/myexperiment-rest_rb.html +0 -64
- data/doc/rdoc/rdoc.css +0 -763
@@ -1,175 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
3
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
<head>
|
6
|
-
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
7
|
-
|
8
|
-
<title>Module: MyExperimentREST::Urls</title>
|
9
|
-
|
10
|
-
<link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
|
11
|
-
|
12
|
-
<script src="../js/jquery.js" type="text/javascript" charset="utf-8"></script>
|
13
|
-
<script src="../js/thickbox-compressed.js" type="text/javascript" charset="utf-8"></script>
|
14
|
-
<script src="../js/quicksearch.js" type="text/javascript" charset="utf-8"></script>
|
15
|
-
<script src="../js/darkfish.js" type="text/javascript" charset="utf-8"></script>
|
16
|
-
|
17
|
-
</head>
|
18
|
-
<body id="top" class="module">
|
19
|
-
|
20
|
-
<div id="metadata">
|
21
|
-
<div id="home-metadata">
|
22
|
-
<div id="home-section" class="section">
|
23
|
-
<h3 class="section-header">
|
24
|
-
<a href="../index.html">Home</a>
|
25
|
-
<a href="../index.html#classes">Classes</a>
|
26
|
-
<a href="../index.html#methods">Methods</a>
|
27
|
-
</h3>
|
28
|
-
</div>
|
29
|
-
</div>
|
30
|
-
|
31
|
-
<div id="file-metadata">
|
32
|
-
<div id="file-list-section" class="section">
|
33
|
-
<h3 class="section-header">In Files</h3>
|
34
|
-
<div class="section-body">
|
35
|
-
<ul>
|
36
|
-
|
37
|
-
<li><a href="../lib/myexperiment-rest/constants_rb.html?TB_iframe=true&height=550&width=785"
|
38
|
-
class="thickbox" title="lib/myexperiment-rest/constants.rb">lib/myexperiment-rest/constants.rb</a></li>
|
39
|
-
|
40
|
-
</ul>
|
41
|
-
</div>
|
42
|
-
</div>
|
43
|
-
|
44
|
-
|
45
|
-
</div>
|
46
|
-
|
47
|
-
<div id="class-metadata">
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
</div>
|
58
|
-
|
59
|
-
<div id="project-metadata">
|
60
|
-
|
61
|
-
|
62
|
-
<div id="fileindex-section" class="section project-section">
|
63
|
-
<h3 class="section-header">Files</h3>
|
64
|
-
<ul>
|
65
|
-
|
66
|
-
<li class="file"><a href="../CHANGES.html">CHANGES</a></li>
|
67
|
-
|
68
|
-
<li class="file"><a href="../LICENSE.html">LICENSE</a></li>
|
69
|
-
|
70
|
-
<li class="file"><a href="../README.html">README</a></li>
|
71
|
-
|
72
|
-
</ul>
|
73
|
-
</div>
|
74
|
-
|
75
|
-
|
76
|
-
<div id="classindex-section" class="section project-section">
|
77
|
-
<h3 class="section-header">Class/Module Index
|
78
|
-
<span class="search-toggle"><img src="../images/find.png"
|
79
|
-
height="16" width="16" alt="[+]"
|
80
|
-
title="show/hide quicksearch" /></span></h3>
|
81
|
-
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
82
|
-
<fieldset>
|
83
|
-
<legend>Quicksearch</legend>
|
84
|
-
<input type="text" name="quicksearch" value=""
|
85
|
-
class="quicksearch-field" />
|
86
|
-
</fieldset>
|
87
|
-
</form>
|
88
|
-
|
89
|
-
<ul class="link-list">
|
90
|
-
|
91
|
-
<li><a href="../MyExperimentREST.html">MyExperimentREST</a></li>
|
92
|
-
|
93
|
-
<li><a href="../MyExperimentREST/MyExperimentIOData.html">MyExperimentREST::MyExperimentIOData</a></li>
|
94
|
-
|
95
|
-
<li><a href="../MyExperimentREST/MyExperimentUser.html">MyExperimentREST::MyExperimentUser</a></li>
|
96
|
-
|
97
|
-
<li><a href="../MyExperimentREST/MyExperimentWorkflow.html">MyExperimentREST::MyExperimentWorkflow</a></li>
|
98
|
-
|
99
|
-
<li><a href="../MyExperimentREST/SessionCookie.html">MyExperimentREST::SessionCookie</a></li>
|
100
|
-
|
101
|
-
<li><a href="../MyExperimentREST/Urls.html">MyExperimentREST::Urls</a></li>
|
102
|
-
|
103
|
-
<li><a href="../MyExperimentREST/User.html">MyExperimentREST::User</a></li>
|
104
|
-
|
105
|
-
<li><a href="../MyExperimentREST/Workflow.html">MyExperimentREST::Workflow</a></li>
|
106
|
-
|
107
|
-
</ul>
|
108
|
-
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
109
|
-
</div>
|
110
|
-
|
111
|
-
|
112
|
-
</div>
|
113
|
-
</div>
|
114
|
-
|
115
|
-
<div id="documentation">
|
116
|
-
<h1 class="module">MyExperimentREST::Urls</h1>
|
117
|
-
|
118
|
-
<div id="description" class="description">
|
119
|
-
|
120
|
-
</div><!-- description -->
|
121
|
-
|
122
|
-
|
123
|
-
<div id="5Buntitled-5D" class="documentation-section">
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
<!-- Constants -->
|
130
|
-
<div id="constants-list" class="section">
|
131
|
-
<h3 class="section-header">Constants</h3>
|
132
|
-
<dl>
|
133
|
-
|
134
|
-
<dt><a name="MYEXPERIMENT_URL">MYEXPERIMENT_URL</a></dt>
|
135
|
-
|
136
|
-
<dd class="description"><p>URL constants</p></dd>
|
137
|
-
|
138
|
-
|
139
|
-
<dt><a name="SESSION_URL">SESSION_URL</a></dt>
|
140
|
-
|
141
|
-
<dd class="description"></dd>
|
142
|
-
|
143
|
-
|
144
|
-
<dt><a name="USER_URL">USER_URL</a></dt>
|
145
|
-
|
146
|
-
<dd class="description"></dd>
|
147
|
-
|
148
|
-
|
149
|
-
<dt><a name="WORKFLOW_URL">WORKFLOW_URL</a></dt>
|
150
|
-
|
151
|
-
<dd class="description"></dd>
|
152
|
-
|
153
|
-
|
154
|
-
</dl>
|
155
|
-
</div>
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
<!-- Methods -->
|
161
|
-
|
162
|
-
</div><!-- 5Buntitled-5D -->
|
163
|
-
|
164
|
-
|
165
|
-
</div><!-- documentation -->
|
166
|
-
|
167
|
-
<div id="validator-badges">
|
168
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
169
|
-
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
170
|
-
Rdoc Generator</a> 2</small>.</p>
|
171
|
-
</div>
|
172
|
-
|
173
|
-
</body>
|
174
|
-
</html>
|
175
|
-
|
@@ -1,262 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
3
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
<head>
|
6
|
-
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
7
|
-
|
8
|
-
<title>Class: MyExperimentREST::User</title>
|
9
|
-
|
10
|
-
<link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
|
11
|
-
|
12
|
-
<script src="../js/jquery.js" type="text/javascript" charset="utf-8"></script>
|
13
|
-
<script src="../js/thickbox-compressed.js" type="text/javascript" charset="utf-8"></script>
|
14
|
-
<script src="../js/quicksearch.js" type="text/javascript" charset="utf-8"></script>
|
15
|
-
<script src="../js/darkfish.js" type="text/javascript" charset="utf-8"></script>
|
16
|
-
|
17
|
-
</head>
|
18
|
-
<body id="top" class="class">
|
19
|
-
|
20
|
-
<div id="metadata">
|
21
|
-
<div id="home-metadata">
|
22
|
-
<div id="home-section" class="section">
|
23
|
-
<h3 class="section-header">
|
24
|
-
<a href="../index.html">Home</a>
|
25
|
-
<a href="../index.html#classes">Classes</a>
|
26
|
-
<a href="../index.html#methods">Methods</a>
|
27
|
-
</h3>
|
28
|
-
</div>
|
29
|
-
</div>
|
30
|
-
|
31
|
-
<div id="file-metadata">
|
32
|
-
<div id="file-list-section" class="section">
|
33
|
-
<h3 class="section-header">In Files</h3>
|
34
|
-
<div class="section-body">
|
35
|
-
<ul>
|
36
|
-
|
37
|
-
<li><a href="../lib/myexperiment-rest/user_rb.html?TB_iframe=true&height=550&width=785"
|
38
|
-
class="thickbox" title="lib/myexperiment-rest/user.rb">lib/myexperiment-rest/user.rb</a></li>
|
39
|
-
|
40
|
-
</ul>
|
41
|
-
</div>
|
42
|
-
</div>
|
43
|
-
|
44
|
-
|
45
|
-
</div>
|
46
|
-
|
47
|
-
<div id="class-metadata">
|
48
|
-
|
49
|
-
<!-- Parent Class -->
|
50
|
-
<div id="parent-class-section" class="section">
|
51
|
-
<h3 class="section-header">Parent</h3>
|
52
|
-
|
53
|
-
<p class="link">Object</p>
|
54
|
-
|
55
|
-
</div>
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
<!-- Method Quickref -->
|
64
|
-
<div id="method-list-section" class="section">
|
65
|
-
<h3 class="section-header">Methods</h3>
|
66
|
-
<ul class="link-list">
|
67
|
-
|
68
|
-
<li><a href="#method-c-from_id">::from_id</a></li>
|
69
|
-
|
70
|
-
<li><a href="#method-c-from_uri">::from_uri</a></li>
|
71
|
-
|
72
|
-
</ul>
|
73
|
-
</div>
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
</div>
|
78
|
-
|
79
|
-
<div id="project-metadata">
|
80
|
-
|
81
|
-
|
82
|
-
<div id="fileindex-section" class="section project-section">
|
83
|
-
<h3 class="section-header">Files</h3>
|
84
|
-
<ul>
|
85
|
-
|
86
|
-
<li class="file"><a href="../CHANGES.html">CHANGES</a></li>
|
87
|
-
|
88
|
-
<li class="file"><a href="../LICENSE.html">LICENSE</a></li>
|
89
|
-
|
90
|
-
<li class="file"><a href="../README.html">README</a></li>
|
91
|
-
|
92
|
-
</ul>
|
93
|
-
</div>
|
94
|
-
|
95
|
-
|
96
|
-
<div id="classindex-section" class="section project-section">
|
97
|
-
<h3 class="section-header">Class/Module Index
|
98
|
-
<span class="search-toggle"><img src="../images/find.png"
|
99
|
-
height="16" width="16" alt="[+]"
|
100
|
-
title="show/hide quicksearch" /></span></h3>
|
101
|
-
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
102
|
-
<fieldset>
|
103
|
-
<legend>Quicksearch</legend>
|
104
|
-
<input type="text" name="quicksearch" value=""
|
105
|
-
class="quicksearch-field" />
|
106
|
-
</fieldset>
|
107
|
-
</form>
|
108
|
-
|
109
|
-
<ul class="link-list">
|
110
|
-
|
111
|
-
<li><a href="../MyExperimentREST.html">MyExperimentREST</a></li>
|
112
|
-
|
113
|
-
<li><a href="../MyExperimentREST/MyExperimentIOData.html">MyExperimentREST::MyExperimentIOData</a></li>
|
114
|
-
|
115
|
-
<li><a href="../MyExperimentREST/MyExperimentUser.html">MyExperimentREST::MyExperimentUser</a></li>
|
116
|
-
|
117
|
-
<li><a href="../MyExperimentREST/MyExperimentWorkflow.html">MyExperimentREST::MyExperimentWorkflow</a></li>
|
118
|
-
|
119
|
-
<li><a href="../MyExperimentREST/SessionCookie.html">MyExperimentREST::SessionCookie</a></li>
|
120
|
-
|
121
|
-
<li><a href="../MyExperimentREST/Urls.html">MyExperimentREST::Urls</a></li>
|
122
|
-
|
123
|
-
<li><a href="../MyExperimentREST/User.html">MyExperimentREST::User</a></li>
|
124
|
-
|
125
|
-
<li><a href="../MyExperimentREST/Workflow.html">MyExperimentREST::Workflow</a></li>
|
126
|
-
|
127
|
-
</ul>
|
128
|
-
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
129
|
-
</div>
|
130
|
-
|
131
|
-
|
132
|
-
</div>
|
133
|
-
</div>
|
134
|
-
|
135
|
-
<div id="documentation">
|
136
|
-
<h1 class="class">MyExperimentREST::User</h1>
|
137
|
-
|
138
|
-
<div id="description" class="description">
|
139
|
-
|
140
|
-
<p>Connects to myExperiment REST API and creates a <em><a
|
141
|
-
href="MyExperimentUser.html">MyExperimentUser</a></em> object.</p>
|
142
|
-
|
143
|
-
</div><!-- description -->
|
144
|
-
|
145
|
-
|
146
|
-
<div id="5Buntitled-5D" class="documentation-section">
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
<!-- Methods -->
|
156
|
-
|
157
|
-
<div id="public-class-method-details" class="method-section section">
|
158
|
-
<h3 class="section-header">Public Class Methods</h3>
|
159
|
-
|
160
|
-
|
161
|
-
<div id="from_id-method" class="method-detail ">
|
162
|
-
<a name="method-c-from_id"></a>
|
163
|
-
|
164
|
-
|
165
|
-
<div class="method-heading">
|
166
|
-
<span class="method-name">from_id</span><span
|
167
|
-
class="method-args">(user_id)</span>
|
168
|
-
<span class="method-click-advice">click to toggle source</span>
|
169
|
-
</div>
|
170
|
-
|
171
|
-
|
172
|
-
<div class="method-description">
|
173
|
-
|
174
|
-
<p>Returns a <em><a href="MyExperimentUser.html">MyExperimentUser</a></em>
|
175
|
-
object given a myExperiment id for that user.</p>
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
<div class="method-source-code" id="from_id-source">
|
180
|
-
<pre>
|
181
|
-
<span class="ruby-comment"># File lib/myexperiment-rest/user.rb, line 31</span>
|
182
|
-
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">from_id</span>(<span class="ruby-identifier">user_id</span>)
|
183
|
-
|
184
|
-
<span class="ruby-comment"># Get user resource information</span>
|
185
|
-
<span class="ruby-identifier">xml</span> = <span class="ruby-constant">MyExperimentREST</span>.<span class="ruby-identifier">get_myexperiment_data</span>(<span class="ruby-constant">Urls</span><span class="ruby-operator">::</span><span class="ruby-constant">USER_URL</span>, <span class="ruby-value">:id</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">user_id</span>)
|
186
|
-
|
187
|
-
<span class="ruby-constant">MyExperimentUser</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">xml</span>)
|
188
|
-
<span class="ruby-keyword">end</span></pre>
|
189
|
-
</div><!-- from_id-source -->
|
190
|
-
|
191
|
-
</div>
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
</div><!-- from_id-method -->
|
197
|
-
|
198
|
-
|
199
|
-
<div id="from_uri-method" class="method-detail ">
|
200
|
-
<a name="method-c-from_uri"></a>
|
201
|
-
|
202
|
-
|
203
|
-
<div class="method-heading">
|
204
|
-
<span class="method-name">from_uri</span><span
|
205
|
-
class="method-args">(uri)</span>
|
206
|
-
<span class="method-click-advice">click to toggle source</span>
|
207
|
-
</div>
|
208
|
-
|
209
|
-
|
210
|
-
<div class="method-description">
|
211
|
-
|
212
|
-
<p>Returns a <em><a href="MyExperimentUser.html">MyExperimentUser</a></em>
|
213
|
-
object given a URI of the user in the repository as a String.</p>
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
<div class="method-source-code" id="from_uri-source">
|
218
|
-
<pre>
|
219
|
-
<span class="ruby-comment"># File lib/myexperiment-rest/user.rb, line 11</span>
|
220
|
-
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">from_uri</span>(<span class="ruby-identifier">uri</span>)
|
221
|
-
|
222
|
-
<span class="ruby-identifier">user_id</span> = <span class="ruby-string">''</span>
|
223
|
-
|
224
|
-
<span class="ruby-comment"># Get user id - will match both user/74 and users.xml?id=74</span>
|
225
|
-
<span class="ruby-identifier">uri_id</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp">/user.*[\/?](id=)?(\d+)/</span>)
|
226
|
-
<span class="ruby-keyword">if</span> <span class="ruby-identifier">uri_id</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword">nil</span>
|
227
|
-
<span class="ruby-identifier">user_id</span> = <span class="ruby-identifier">uri_id</span>[<span class="ruby-value">2</span>]
|
228
|
-
<span class="ruby-keyword">else</span>
|
229
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-string">"Could not match user id."</span>
|
230
|
-
<span class="ruby-keyword">end</span>
|
231
|
-
|
232
|
-
<span class="ruby-comment"># Get user resource information</span>
|
233
|
-
<span class="ruby-identifier">xml</span> = <span class="ruby-constant">MyExperimentREST</span>.<span class="ruby-identifier">get_myexperiment_data</span>(<span class="ruby-constant">Urls</span><span class="ruby-operator">::</span><span class="ruby-constant">USER_URL</span>, <span class="ruby-value">:id</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">user_id</span>)
|
234
|
-
|
235
|
-
<span class="ruby-constant">MyExperimentUser</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">xml</span>)
|
236
|
-
<span class="ruby-keyword">end</span></pre>
|
237
|
-
</div><!-- from_uri-source -->
|
238
|
-
|
239
|
-
</div>
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
</div><!-- from_uri-method -->
|
245
|
-
|
246
|
-
|
247
|
-
</div><!-- public-class-method-details -->
|
248
|
-
|
249
|
-
</div><!-- 5Buntitled-5D -->
|
250
|
-
|
251
|
-
|
252
|
-
</div><!-- documentation -->
|
253
|
-
|
254
|
-
<div id="validator-badges">
|
255
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
256
|
-
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
257
|
-
Rdoc Generator</a> 2</small>.</p>
|
258
|
-
</div>
|
259
|
-
|
260
|
-
</body>
|
261
|
-
</html>
|
262
|
-
|
@@ -1,271 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
3
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
<head>
|
6
|
-
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
7
|
-
|
8
|
-
<title>Class: MyExperimentREST::Workflow</title>
|
9
|
-
|
10
|
-
<link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
|
11
|
-
|
12
|
-
<script src="../js/jquery.js" type="text/javascript" charset="utf-8"></script>
|
13
|
-
<script src="../js/thickbox-compressed.js" type="text/javascript" charset="utf-8"></script>
|
14
|
-
<script src="../js/quicksearch.js" type="text/javascript" charset="utf-8"></script>
|
15
|
-
<script src="../js/darkfish.js" type="text/javascript" charset="utf-8"></script>
|
16
|
-
|
17
|
-
</head>
|
18
|
-
<body id="top" class="class">
|
19
|
-
|
20
|
-
<div id="metadata">
|
21
|
-
<div id="home-metadata">
|
22
|
-
<div id="home-section" class="section">
|
23
|
-
<h3 class="section-header">
|
24
|
-
<a href="../index.html">Home</a>
|
25
|
-
<a href="../index.html#classes">Classes</a>
|
26
|
-
<a href="../index.html#methods">Methods</a>
|
27
|
-
</h3>
|
28
|
-
</div>
|
29
|
-
</div>
|
30
|
-
|
31
|
-
<div id="file-metadata">
|
32
|
-
<div id="file-list-section" class="section">
|
33
|
-
<h3 class="section-header">In Files</h3>
|
34
|
-
<div class="section-body">
|
35
|
-
<ul>
|
36
|
-
|
37
|
-
<li><a href="../lib/myexperiment-rest/workflow_rb.html?TB_iframe=true&height=550&width=785"
|
38
|
-
class="thickbox" title="lib/myexperiment-rest/workflow.rb">lib/myexperiment-rest/workflow.rb</a></li>
|
39
|
-
|
40
|
-
</ul>
|
41
|
-
</div>
|
42
|
-
</div>
|
43
|
-
|
44
|
-
|
45
|
-
</div>
|
46
|
-
|
47
|
-
<div id="class-metadata">
|
48
|
-
|
49
|
-
<!-- Parent Class -->
|
50
|
-
<div id="parent-class-section" class="section">
|
51
|
-
<h3 class="section-header">Parent</h3>
|
52
|
-
|
53
|
-
<p class="link">Object</p>
|
54
|
-
|
55
|
-
</div>
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
<!-- Method Quickref -->
|
64
|
-
<div id="method-list-section" class="section">
|
65
|
-
<h3 class="section-header">Methods</h3>
|
66
|
-
<ul class="link-list">
|
67
|
-
|
68
|
-
<li><a href="#method-c-from_id_and_version">::from_id_and_version</a></li>
|
69
|
-
|
70
|
-
<li><a href="#method-c-from_uri">::from_uri</a></li>
|
71
|
-
|
72
|
-
</ul>
|
73
|
-
</div>
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
</div>
|
78
|
-
|
79
|
-
<div id="project-metadata">
|
80
|
-
|
81
|
-
|
82
|
-
<div id="fileindex-section" class="section project-section">
|
83
|
-
<h3 class="section-header">Files</h3>
|
84
|
-
<ul>
|
85
|
-
|
86
|
-
<li class="file"><a href="../CHANGES.html">CHANGES</a></li>
|
87
|
-
|
88
|
-
<li class="file"><a href="../LICENSE.html">LICENSE</a></li>
|
89
|
-
|
90
|
-
<li class="file"><a href="../README.html">README</a></li>
|
91
|
-
|
92
|
-
</ul>
|
93
|
-
</div>
|
94
|
-
|
95
|
-
|
96
|
-
<div id="classindex-section" class="section project-section">
|
97
|
-
<h3 class="section-header">Class/Module Index
|
98
|
-
<span class="search-toggle"><img src="../images/find.png"
|
99
|
-
height="16" width="16" alt="[+]"
|
100
|
-
title="show/hide quicksearch" /></span></h3>
|
101
|
-
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
102
|
-
<fieldset>
|
103
|
-
<legend>Quicksearch</legend>
|
104
|
-
<input type="text" name="quicksearch" value=""
|
105
|
-
class="quicksearch-field" />
|
106
|
-
</fieldset>
|
107
|
-
</form>
|
108
|
-
|
109
|
-
<ul class="link-list">
|
110
|
-
|
111
|
-
<li><a href="../MyExperimentREST.html">MyExperimentREST</a></li>
|
112
|
-
|
113
|
-
<li><a href="../MyExperimentREST/MyExperimentIOData.html">MyExperimentREST::MyExperimentIOData</a></li>
|
114
|
-
|
115
|
-
<li><a href="../MyExperimentREST/MyExperimentUser.html">MyExperimentREST::MyExperimentUser</a></li>
|
116
|
-
|
117
|
-
<li><a href="../MyExperimentREST/MyExperimentWorkflow.html">MyExperimentREST::MyExperimentWorkflow</a></li>
|
118
|
-
|
119
|
-
<li><a href="../MyExperimentREST/SessionCookie.html">MyExperimentREST::SessionCookie</a></li>
|
120
|
-
|
121
|
-
<li><a href="../MyExperimentREST/Urls.html">MyExperimentREST::Urls</a></li>
|
122
|
-
|
123
|
-
<li><a href="../MyExperimentREST/User.html">MyExperimentREST::User</a></li>
|
124
|
-
|
125
|
-
<li><a href="../MyExperimentREST/Workflow.html">MyExperimentREST::Workflow</a></li>
|
126
|
-
|
127
|
-
</ul>
|
128
|
-
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
129
|
-
</div>
|
130
|
-
|
131
|
-
|
132
|
-
</div>
|
133
|
-
</div>
|
134
|
-
|
135
|
-
<div id="documentation">
|
136
|
-
<h1 class="class">MyExperimentREST::Workflow</h1>
|
137
|
-
|
138
|
-
<div id="description" class="description">
|
139
|
-
|
140
|
-
<p>Connects to myExperiment REST API and creates a <em><a
|
141
|
-
href="MyExperimentWorkflow.html">MyExperimentWorkflow</a></em> object.</p>
|
142
|
-
|
143
|
-
</div><!-- description -->
|
144
|
-
|
145
|
-
|
146
|
-
<div id="5Buntitled-5D" class="documentation-section">
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
<!-- Methods -->
|
156
|
-
|
157
|
-
<div id="public-class-method-details" class="method-section section">
|
158
|
-
<h3 class="section-header">Public Class Methods</h3>
|
159
|
-
|
160
|
-
|
161
|
-
<div id="from_id_and_version-method" class="method-detail ">
|
162
|
-
<a name="method-c-from_id_and_version"></a>
|
163
|
-
|
164
|
-
|
165
|
-
<div class="method-heading">
|
166
|
-
<span class="method-name">from_id_and_version</span><span
|
167
|
-
class="method-args">(id, version='', session_cookie={})</span>
|
168
|
-
<span class="method-click-advice">click to toggle source</span>
|
169
|
-
</div>
|
170
|
-
|
171
|
-
|
172
|
-
<div class="method-description">
|
173
|
-
|
174
|
-
<p>Returns a <em><a
|
175
|
-
href="MyExperimentWorkflow.html">MyExperimentWorkflow</a></em> object given
|
176
|
-
a myExperiment id and version for that workflow.</p>
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
<div class="method-source-code" id="from_id_and_version-source">
|
181
|
-
<pre>
|
182
|
-
<span class="ruby-comment"># File lib/myexperiment-rest/workflow.rb, line 38</span>
|
183
|
-
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">from_id_and_version</span>(<span class="ruby-identifier">id</span>, <span class="ruby-identifier">version</span>=<span class="ruby-string">''</span>, <span class="ruby-identifier">session_cookie</span>={})
|
184
|
-
|
185
|
-
<span class="ruby-comment"># Get workflow resource information</span>
|
186
|
-
<span class="ruby-identifier">xml</span> = <span class="ruby-constant">MyExperimentREST</span>.<span class="ruby-identifier">get_myexperiment_data</span>(<span class="ruby-constant">Urls</span><span class="ruby-operator">::</span><span class="ruby-constant">WORKFLOW_URL</span>, <span class="ruby-value">:id</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">id</span>, <span class="ruby-value">:version</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">version</span>, <span class="ruby-value">:session_cookie</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">session_cookie</span>)
|
187
|
-
|
188
|
-
<span class="ruby-constant">MyExperimentWorkflow</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">xml</span>)
|
189
|
-
<span class="ruby-keyword">end</span></pre>
|
190
|
-
</div><!-- from_id_and_version-source -->
|
191
|
-
|
192
|
-
</div>
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
</div><!-- from_id_and_version-method -->
|
198
|
-
|
199
|
-
|
200
|
-
<div id="from_uri-method" class="method-detail ">
|
201
|
-
<a name="method-c-from_uri"></a>
|
202
|
-
|
203
|
-
|
204
|
-
<div class="method-heading">
|
205
|
-
<span class="method-name">from_uri</span><span
|
206
|
-
class="method-args">(uri, session_cookie={})</span>
|
207
|
-
<span class="method-click-advice">click to toggle source</span>
|
208
|
-
</div>
|
209
|
-
|
210
|
-
|
211
|
-
<div class="method-description">
|
212
|
-
|
213
|
-
<p>Returns a <em><a
|
214
|
-
href="MyExperimentWorkflow.html">MyExperimentWorkflow</a></em> object given
|
215
|
-
a URI of the workflow in the repository as a String.</p>
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
<div class="method-source-code" id="from_uri-source">
|
220
|
-
<pre>
|
221
|
-
<span class="ruby-comment"># File lib/myexperiment-rest/workflow.rb, line 11</span>
|
222
|
-
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">from_uri</span>(<span class="ruby-identifier">uri</span>, <span class="ruby-identifier">session_cookie</span>={})
|
223
|
-
|
224
|
-
<span class="ruby-identifier">workflow_id</span> = <span class="ruby-string">''</span>
|
225
|
-
<span class="ruby-identifier">workflow_version</span> = <span class="ruby-string">''</span>
|
226
|
-
|
227
|
-
<span class="ruby-comment"># Get workflow id - will match both workflow/74 and workflows.xml?id=74</span>
|
228
|
-
<span class="ruby-identifier">uri_id</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp">/workflow.*[\/?](id=)?(\d+)/</span>)
|
229
|
-
<span class="ruby-keyword">if</span> <span class="ruby-identifier">uri_id</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword">nil</span>
|
230
|
-
<span class="ruby-identifier">workflow_id</span> = <span class="ruby-identifier">uri_id</span>[<span class="ruby-value">2</span>]
|
231
|
-
<span class="ruby-keyword">else</span>
|
232
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-string">"Could not match workflow id."</span>
|
233
|
-
<span class="ruby-keyword">end</span>
|
234
|
-
|
235
|
-
<span class="ruby-comment"># Get workflow version if it exists</span>
|
236
|
-
<span class="ruby-identifier">uri_version</span> = <span class="ruby-identifier">uri</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp">/version=(\d+)/</span>)
|
237
|
-
<span class="ruby-keyword">if</span> <span class="ruby-identifier">uri_version</span> <span class="ruby-operator">!=</span> <span class="ruby-keyword">nil</span>
|
238
|
-
<span class="ruby-identifier">workflow_version</span> = <span class="ruby-identifier">uri_version</span>[<span class="ruby-value">1</span>]
|
239
|
-
<span class="ruby-keyword">end</span>
|
240
|
-
|
241
|
-
<span class="ruby-comment"># Get workflow resource information </span>
|
242
|
-
<span class="ruby-identifier">xml</span> = <span class="ruby-constant">MyExperimentREST</span>.<span class="ruby-identifier">get_myexperiment_data</span>(<span class="ruby-constant">Urls</span><span class="ruby-operator">::</span><span class="ruby-constant">WORKFLOW_URL</span>, <span class="ruby-value">:id</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">workflow_id</span>, <span class="ruby-value">:version</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">workflow_version</span>, <span class="ruby-value">:session_cookie</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">session_cookie</span>)
|
243
|
-
|
244
|
-
<span class="ruby-constant">MyExperimentWorkflow</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">xml</span>)
|
245
|
-
<span class="ruby-keyword">end</span></pre>
|
246
|
-
</div><!-- from_uri-source -->
|
247
|
-
|
248
|
-
</div>
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
</div><!-- from_uri-method -->
|
254
|
-
|
255
|
-
|
256
|
-
</div><!-- public-class-method-details -->
|
257
|
-
|
258
|
-
</div><!-- 5Buntitled-5D -->
|
259
|
-
|
260
|
-
|
261
|
-
</div><!-- documentation -->
|
262
|
-
|
263
|
-
<div id="validator-badges">
|
264
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
265
|
-
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
266
|
-
Rdoc Generator</a> 2</small>.</p>
|
267
|
-
</div>
|
268
|
-
|
269
|
-
</body>
|
270
|
-
</html>
|
271
|
-
|