X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=webservices%2Fcompbio%2Fws%2Fclient%2FCmdHelper.java;h=509abcc49b7d0872c3a747a1a261f900bd12ec15;hb=520d44d645eafb8b8f8e6d8a2a0f55a094fcc0ff;hp=1faf3dc8cb3ca063175821d578ad5b168d5b2c87;hpb=6e1c873d0879f462b1fb1a1efa444cf993a9e76a;p=jabaws.git diff --git a/webservices/compbio/ws/client/CmdHelper.java b/webservices/compbio/ws/client/CmdHelper.java index 1faf3dc..509abcc 100644 --- a/webservices/compbio/ws/client/CmdHelper.java +++ b/webservices/compbio/ws/client/CmdHelper.java @@ -1,11 +1,30 @@ +/* Copyright (c) 2011 Peter Troshin + * + * JAva Bioinformatics Analysis Web Services (JABAWS) @version: 2.0 + * + * This library is free software; you can redistribute it and/or modify it under the terms of the + * Apache License version 2 as published by the Apache Software Foundation + * + * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without + * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the Apache + * License for more details. + * + * A copy of the license is in apache_license.txt. It is also available here: + * @see: http://www.apache.org/licenses/LICENSE-2.0.txt + * + * Any republication or derived work distributed in source code form + * must include this copyright and license notice. + */ package compbio.ws.client; import static compbio.ws.client.Constraints.hostkey; import static compbio.ws.client.Constraints.limitList; +import static compbio.ws.client.Constraints.listServices; import static compbio.ws.client.Constraints.paramList; import static compbio.ws.client.Constraints.presetList; import static compbio.ws.client.Constraints.presetkey; import static compbio.ws.client.Constraints.pseparator; import static compbio.ws.client.Constraints.servicekey; +import static compbio.ws.client.Constraints.testKey; class CmdHelper { @@ -32,6 +51,26 @@ class CmdHelper { } /** + * list available services + * + * @param cmd + * @return + */ + static boolean listServices(String[] cmd) { + return keyFound(cmd, listServices); + } + + /** + * tests service + * + * @param cmd + * @return + */ + static boolean testService(String[] cmd) { + return keyFound(cmd, testKey); + } + + /** * Checks whether the key is in the command line * * @param cmd