ac2be712b31bfd1b702235da1f2f59930a279ad0
[jabaws.git] / website / full_javadoc / compbio / engine / SyncExecutor.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">\r
2 <!--NewPage-->\r
3 <HTML>\r
4 <HEAD>\r
5 <!-- Generated by javadoc (build 1.6.0_14) on Wed Feb 17 16:46:49 GMT 2010 -->\r
6 <TITLE>\r
7 SyncExecutor\r
8 </TITLE>\r
9 \r
10 <META NAME="date" CONTENT="2010-02-17">\r
11 \r
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style">\r
13 \r
14 <SCRIPT type="text/javascript">\r
15 function windowTitle()\r
16 {\r
17     if (location.href.indexOf('is-external=true') == -1) {\r
18         parent.document.title="SyncExecutor";\r
19     }\r
20 }\r
21 </SCRIPT>\r
22 <NOSCRIPT>\r
23 </NOSCRIPT>\r
24 \r
25 </HEAD>\r
26 \r
27 <BODY BGCOLOR="white" onload="windowTitle();">\r
28 <HR>\r
29 \r
30 \r
31 <!-- ========= START OF TOP NAVBAR ======= -->\r
32 <A NAME="navbar_top"><!-- --></A>\r
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>\r
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">\r
35 <TR>\r
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">\r
37 <A NAME="navbar_top_firstrow"><!-- --></A>\r
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">\r
39   <TR ALIGN="center" VALIGN="top">\r
40   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>\r
41   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>\r
42   <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>\r
43   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/SyncExecutor.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>\r
44   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>\r
45   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>\r
46   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>\r
47   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>\r
48   </TR>\r
49 </TABLE>\r
50 </TD>\r
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>\r
52 </EM>\r
53 </TD>\r
54 </TR>\r
55 \r
56 <TR>\r
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
58 &nbsp;<A HREF="../../compbio/engine/SubmissionManager.html" title="class in compbio.engine"><B>PREV CLASS</B></A>&nbsp;\r
59 &nbsp;NEXT CLASS</FONT></TD>\r
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
61   <A HREF="../../index.html?compbio/engine/SyncExecutor.html" target="_top"><B>FRAMES</B></A>  &nbsp;\r
62 &nbsp;<A HREF="SyncExecutor.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;\r
63 &nbsp;<SCRIPT type="text/javascript">\r
64   <!--\r
65   if(window==top) {\r
66     document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');\r
67   }\r
68   //-->\r
69 </SCRIPT>\r
70 <NOSCRIPT>\r
71   <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>\r
72 </NOSCRIPT>\r
73 \r
74 \r
75 </FONT></TD>\r
76 </TR>\r
77 <TR>\r
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
79   SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>\r
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>\r
82 </TR>\r
83 </TABLE>\r
84 <A NAME="skip-navbar_top"></A>\r
85 <!-- ========= END OF TOP NAVBAR ========= -->\r
86 \r
87 <HR>\r
88 <!-- ======== START OF CLASS DATA ======== -->\r
89 <H2>\r
90 <FONT SIZE="-1">\r
91 compbio.engine</FONT>\r
92 <BR>\r
93 Interface SyncExecutor</H2>\r
94 <DL>\r
95 <DT><B>All Known Implementing Classes:</B> <DD><A HREF="../../compbio/engine/cluster/drmaa/JobRunner.html" title="class in compbio.engine.cluster.drmaa">JobRunner</A>, <A HREF="../../compbio/engine/local/LocalRunner.html" title="class in compbio.engine.local">LocalRunner</A></DD>\r
96 </DL>\r
97 <HR>\r
98 <DL>\r
99 <DT><PRE>public interface <B>SyncExecutor</B></DL>\r
100 </PRE>\r
101 \r
102 <P>\r
103 Synchronous executor, is an engine to run the Executable synchronously.\r
104 <P>\r
105 \r
106 <P>\r
107 <DL>\r
108 <DT><B>Author:</B></DT>\r
109   <DD>pvtroshin
110                 Date October 2009</DD>\r
111 </DL>\r
112 <HR>\r
113 \r
114 <P>\r
115 \r
116 <!-- ========== METHOD SUMMARY =========== -->\r
117 \r
118 <A NAME="method_summary"><!-- --></A>\r
119 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
120 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
121 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">\r
122 <B>Method Summary</B></FONT></TH>\r
123 </TR>\r
124 <TR BGCOLOR="white" CLASS="TableRowColor">\r
125 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
126 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
127 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#cancelJob()">cancelJob</A></B>()</CODE>\r
128 \r
129 <BR>\r
130 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Stops running job.</TD>\r
131 </TR>\r
132 <TR BGCOLOR="white" CLASS="TableRowColor">\r
133 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
134 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
135 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#cleanup()">cleanup</A></B>()</CODE>\r
136 \r
137 <BR>\r
138 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Clean up after the job</TD>\r
139 </TR>\r
140 <TR BGCOLOR="white" CLASS="TableRowColor">\r
141 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
142 <CODE>&nbsp;void</CODE></FONT></TD>\r
143 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#executeJob()">executeJob</A></B>()</CODE>\r
144 \r
145 <BR>\r
146 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Execute the job</TD>\r
147 </TR>\r
148 <TR BGCOLOR="white" CLASS="TableRowColor">\r
149 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
150 <CODE>&nbsp;<A HREF="../../compbio/metadata/JobStatus.html" title="enum in compbio.metadata">JobStatus</A></CODE></FONT></TD>\r
151 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#getJobStatus()">getJobStatus</A></B>()</CODE>\r
152 \r
153 <BR>\r
154 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Query the status of the job by its id.</TD>\r
155 </TR>\r
156 <TR BGCOLOR="white" CLASS="TableRowColor">\r
157 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
158 <CODE>&nbsp;java.lang.String</CODE></FONT></TD>\r
159 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#getWorkDirectory()">getWorkDirectory</A></B>()</CODE>\r
160 \r
161 <BR>\r
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>\r
163 </TR>\r
164 <TR BGCOLOR="white" CLASS="TableRowColor">\r
165 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
166 <CODE>&nbsp;<A HREF="../../compbio/engine/client/ConfiguredExecutable.html" title="interface in compbio.engine.client">ConfiguredExecutable</A>&lt;?&gt;</CODE></FONT></TD>\r
167 <TD><CODE><B><A HREF="../../compbio/engine/SyncExecutor.html#waitForResult()">waitForResult</A></B>()</CODE>\r
168 \r
169 <BR>\r
170 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Call to this method block for as long as it is required for an executable to finish its job.</TD>\r
171 </TR>\r
172 </TABLE>\r
173 &nbsp;\r
174 <P>\r
175 \r
176 <!-- ============ METHOD DETAIL ========== -->\r
177 \r
178 <A NAME="method_detail"><!-- --></A>\r
179 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
180 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
181 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">\r
182 <B>Method Detail</B></FONT></TH>\r
183 </TR>\r
184 </TABLE>\r
185 \r
186 <A NAME="executeJob()"><!-- --></A><H3>\r
187 executeJob</H3>\r
188 <PRE>\r
189 void <B>executeJob</B>()\r
190                 throws <A HREF="../../compbio/metadata/JobSubmissionException.html" title="class in compbio.metadata">JobSubmissionException</A></PRE>\r
191 <DL>\r
192 <DD>Execute the job\r
193 <P>\r
194 <DD><DL>\r
195 \r
196 <DT><B>Throws:</B>\r
197 <DD><CODE><A HREF="../../compbio/metadata/JobSubmissionException.html" title="class in compbio.metadata">JobSubmissionException</A></CODE> - if submission fails</DL>\r
198 </DD>\r
199 </DL>\r
200 <HR>\r
201 \r
202 <A NAME="cleanup()"><!-- --></A><H3>\r
203 cleanup</H3>\r
204 <PRE>\r
205 boolean <B>cleanup</B>()</PRE>\r
206 <DL>\r
207 <DD>Clean up after the job\r
208 <P>\r
209 <DD><DL>\r
210 \r
211 <DT><B>Returns:</B><DD>true if all the files created by this job have been removed successfully, false otherwise</DL>\r
212 </DD>\r
213 </DL>\r
214 <HR>\r
215 \r
216 <A NAME="waitForResult()"><!-- --></A><H3>\r
217 waitForResult</H3>\r
218 <PRE>\r
219 <A HREF="../../compbio/engine/client/ConfiguredExecutable.html" title="interface in compbio.engine.client">ConfiguredExecutable</A>&lt;?&gt; <B>waitForResult</B>()\r
220                                       throws <A HREF="../../compbio/metadata/JobExecutionException.html" title="class in compbio.metadata">JobExecutionException</A></PRE>\r
221 <DL>\r
222 <DD>Call to this method block for as long as it is required for an executable to finish its job. 
223  If the calculation has been completed already, the this method returns results immediately. 
224  This could return the result directly, but that would be type unsafe\r
225 <P>\r
226 <DD><DL>\r
227 \r
228 <DT><B>Returns:</B><DD>object from wich the result can be obtained\r
229 <DT><B>Throws:</B>\r
230 <DD><CODE><A HREF="../../compbio/metadata/JobExecutionException.html" title="class in compbio.metadata">JobExecutionException</A></CODE></DL>\r
231 </DD>\r
232 </DL>\r
233 <HR>\r
234 \r
235 <A NAME="getWorkDirectory()"><!-- --></A><H3>\r
236 getWorkDirectory</H3>\r
237 <PRE>\r
238 java.lang.String <B>getWorkDirectory</B>()</PRE>\r
239 <DL>\r
240 <DD><DL>\r
241 \r
242 <DT><B>Returns:</B><DD>working directory if the task</DL>\r
243 </DD>\r
244 </DL>\r
245 <HR>\r
246 \r
247 <A NAME="cancelJob()"><!-- --></A><H3>\r
248 cancelJob</H3>\r
249 <PRE>\r
250 boolean <B>cancelJob</B>()</PRE>\r
251 <DL>\r
252 <DD>Stops running job. 
253  Clean up is not performed.\r
254 <P>\r
255 <DD><DL>\r
256 \r
257 <DT><B>Returns:</B><DD>true if job was cancelled successfully, false otherwise</DL>\r
258 </DD>\r
259 </DL>\r
260 <HR>\r
261 \r
262 <A NAME="getJobStatus()"><!-- --></A><H3>\r
263 getJobStatus</H3>\r
264 <PRE>\r
265 <A HREF="../../compbio/metadata/JobStatus.html" title="enum in compbio.metadata">JobStatus</A> <B>getJobStatus</B>()</PRE>\r
266 <DL>\r
267 <DD>Query the status of the job by its id.\r
268 <P>\r
269 <DD><DL>\r
270 \r
271 <DT><B>Returns:</B><DD>- JobStatus</DL>\r
272 </DD>\r
273 </DL>\r
274 <!-- ========= END OF CLASS DATA ========= -->\r
275 <HR>\r
276 \r
277 \r
278 <!-- ======= START OF BOTTOM NAVBAR ====== -->\r
279 <A NAME="navbar_bottom"><!-- --></A>\r
280 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>\r
281 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">\r
282 <TR>\r
283 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">\r
284 <A NAME="navbar_bottom_firstrow"><!-- --></A>\r
285 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">\r
286   <TR ALIGN="center" VALIGN="top">\r
287   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>\r
288   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>\r
289   <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>\r
290   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/SyncExecutor.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>\r
291   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>\r
292   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>\r
293   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>\r
294   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>\r
295   </TR>\r
296 </TABLE>\r
297 </TD>\r
298 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>\r
299 </EM>\r
300 </TD>\r
301 </TR>\r
302 \r
303 <TR>\r
304 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
305 &nbsp;<A HREF="../../compbio/engine/SubmissionManager.html" title="class in compbio.engine"><B>PREV CLASS</B></A>&nbsp;\r
306 &nbsp;NEXT CLASS</FONT></TD>\r
307 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
308   <A HREF="../../index.html?compbio/engine/SyncExecutor.html" target="_top"><B>FRAMES</B></A>  &nbsp;\r
309 &nbsp;<A HREF="SyncExecutor.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;\r
310 &nbsp;<SCRIPT type="text/javascript">\r
311   <!--\r
312   if(window==top) {\r
313     document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');\r
314   }\r
315   //-->\r
316 </SCRIPT>\r
317 <NOSCRIPT>\r
318   <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>\r
319 </NOSCRIPT>\r
320 \r
321 \r
322 </FONT></TD>\r
323 </TR>\r
324 <TR>\r
325 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
326   SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>\r
327 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
328 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>\r
329 </TR>\r
330 </TABLE>\r
331 <A NAME="skip-navbar_bottom"></A>\r
332 <!-- ======== END OF BOTTOM NAVBAR ======= -->\r
333 \r
334 <HR>\r
335 \r
336 </BODY>\r
337 </HTML>\r