2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.6)
3 * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle
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 of the License, or (at your option) any later version.
11 * Jalview is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
18 package jalview.ws.jws1;
20 import jalview.ws.AWsJob;
22 abstract class WSJob extends AWsJob
27 * @see jalview.ws.AWsJob#clearResponse()
30 public void clearResponse()
38 * @see jalview.ws.AWsJob#hasResponse()
41 public boolean hasResponse()
43 return result != null;
49 * @see jalview.ws.AWsJob#hasStatus()
52 public boolean hasStatus()
54 return result != null && result.getStatus() != null;
58 * The last result object returned by the service.
60 vamsas.objects.simple.Result result;
64 * @see vamsas.objects.simple.Result#getStatus()
66 public String getStatus()
68 return result == null ? null : result.getStatus();
71 public String getState()
73 return result == null ? "NULL result" : "" + result.getState();
78 * @see vamsas.objects.simple.Result#isBroken()
80 public boolean isBroken()
82 return result != null && result.isBroken();
87 * @see vamsas.objects.simple.Result#isFailed()
89 public boolean isFailed()
91 return result != null && result.isFailed();
96 * @see vamsas.objects.simple.Result#isFinished()
98 public boolean isFinished()
100 return result != null && result.isFinished();
105 * @see vamsas.objects.simple.Result#isInvalid()
107 public boolean isInvalid()
109 return result != null && result.isInvalid();
114 * @see vamsas.objects.simple.Result#isJobFailed()
116 public boolean isJobFailed()
118 return result != null && result.isJobFailed();
123 * @see vamsas.objects.simple.Result#isQueued()
125 public boolean isQueued()
127 return result != null && result.isQueued();
132 * @see vamsas.objects.simple.Result#isRunning()
134 public boolean isRunning()
136 return result != null && result.isRunning();
141 * @see vamsas.objects.simple.Result#isServerError()
143 public boolean isServerError()
145 return result != null && result.isServerError();