Add documentation to the classes
[proteocache.git] / server / compbio / ws / jpred / JpredWS.java
index 9978cc4..5249280 100644 (file)
@@ -13,6 +13,15 @@ import compbio.cassandra.CassandraNativeConnector;
 import compbio.cassandra.readers.SequenceReader;
 import compbio.engine.archive.ArchivedJob;
 
+/**
+ * Implementation of the Jpred web service in ProteoCache
+ * 
+ * @author Alexander Sherstnev
+ * @author Natasha Sherstneva
+ * 
+ * @version 1.0
+ * @since Jan 2014
+ */
 @WebService(endpointInterface = "compbio.ws.jpred.Jpred", targetNamespace = "http://server.proteocache.ws", serviceName = "ProteoCacheWS", portName = "ProteoCacheWSPort")
 public class JpredWS implements Jpred {
        private static Logger log = Logger.getLogger(CassandraNativeConnector.class);
@@ -71,7 +80,7 @@ public class JpredWS implements Jpred {
 
        @Override
        public String getArchive(String jobid) {
-               String link = "undefined";
+               String link = null;
                ArchivedJob aj = new ArchivedJob(jobid);
                try {
                        link = aj.prepareJobArchiveToWeb();
@@ -79,6 +88,7 @@ public class JpredWS implements Jpred {
                        log.error("JpredWS.findSequence: IO exception with job archive file");
                        log.error(e.getLocalizedMessage(), e.getCause());
                }
+               // if the archive file is not available null is returned
                return link;
        }