2 * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3 * Copyright (C) $$Year-Rel$$ The Jalview Authors
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3
10 * of the License, or (at your option) any later version.
12 * Jalview is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty
14 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19 * The Jalview Authors are detailed in the 'AUTHORS' file.
21 package jalview.ws.jws1;
23 import jalview.ws.AWsJob;
25 abstract class WSJob extends AWsJob
30 * @see jalview.ws.AWsJob#clearResponse()
33 public void clearResponse()
41 * @see jalview.ws.AWsJob#hasResponse()
44 public boolean hasResponse()
46 return result != null;
52 * @see jalview.ws.AWsJob#hasStatus()
55 public boolean hasStatus()
57 return result != null && result.getStatus() != null;
61 * The last result object returned by the service.
63 vamsas.objects.simple.Result result;
67 * @see vamsas.objects.simple.Result#getStatus()
69 public String getStatus()
71 return result == null ? null : result.getStatus();
74 public String getState()
76 return result == null ? "NULL result" : "" + result.getState();
81 * @see vamsas.objects.simple.Result#isBroken()
83 public boolean isBroken()
85 return result != null && result.isBroken();
90 * @see vamsas.objects.simple.Result#isFailed()
92 public boolean isFailed()
94 return result != null && result.isFailed();
99 * @see vamsas.objects.simple.Result#isFinished()
101 public boolean isFinished()
103 return result != null && result.isFinished();
108 * @see vamsas.objects.simple.Result#isInvalid()
110 public boolean isInvalid()
112 return result != null && result.isInvalid();
117 * @see vamsas.objects.simple.Result#isJobFailed()
119 public boolean isJobFailed()
121 return result != null && result.isJobFailed();
126 * @see vamsas.objects.simple.Result#isQueued()
128 public boolean isQueued()
130 return result != null && result.isQueued();
135 * @see vamsas.objects.simple.Result#isRunning()
137 public boolean isRunning()
139 return result != null && result.isRunning();
144 * @see vamsas.objects.simple.Result#isServerError()
146 public boolean isServerError()
148 return result != null && result.isServerError();