public class TavernaServer extends Object
To construct a TavernaServer
, use
TavernaServerConnectionFactory
.
This class provides the general information from the server, e.g.
getCapabilities()
and getPermittedWorkflows()
.
Use getExistingRuns()
to list existing Run
s, or use
createWorkflowRun(File)
and friends to create a new run.
TavernaServerConnectionFactory
Modifier and Type | Class and Description |
---|---|
static class |
TavernaServer.AuthorizationException |
static class |
TavernaServer.ClientException |
Modifier and Type | Method and Description |
---|---|
Run |
createWorkflowRun(byte[] t2flowBytes)
Create a new Run by uploading the bytes of a t2flow workflow definition.
|
Run |
createWorkflowRun(File t2flowFile)
Create a new Run by uploading a local t2flow workflow definition File.
|
Run |
createWorkflowRun(URI t2flowUri)
Create a new Run by referencing an external t2flow workflow definition URI.
|
List<Capability> |
getCapabilities() |
List<Run> |
getExistingRuns() |
int |
getOperatingLimit() |
List<String> |
getPermittedWorkflows() |
int |
getRunLimit() |
VersionedElement |
getServerVersionInfo() |
TavernaServer |
upgradeToAuth(String username,
String password) |
public TavernaServer upgradeToAuth(String username, String password)
public List<Capability> getCapabilities()
public int getRunLimit()
public int getOperatingLimit()
public VersionedElement getServerVersionInfo()
public Run createWorkflowRun(byte[] t2flowBytes) throws TavernaServer.ClientException, org.apache.taverna.server.client.TavernaServer.ServerException
The returned Run
be configured (e.g. with
Run.setInput(String, String)
) before invoking it
with Run.start()
.
t2flowBytes
- Content of workflow definition file to upload, should be in the format application/vnd.taverna.t2flow+xml
Run
that is Status.Initialized
TavernaServer.ClientException
- If client configuration failed, e.g. AuthorizationExceptionServerException
- If the server refuses upload (e.g. because only getPermittedWorkflows()
are allowed)org.apache.taverna.server.client.TavernaServer.ServerException
public Run createWorkflowRun(File t2flowFile) throws IOException, TavernaServer.ClientException, org.apache.taverna.server.client.TavernaServer.ServerException
The returned Run
be configured (e.g. with
Run.setInput(String, String)
) before invoking it
with Run.start()
.
t2flowFile
- File of workflow to upload, typically with the extension .t2flow
Run
that is Status.Initialized
IOException
- If the file can't be read or a network error occursTavernaServer.ClientException
- If client configuration failed, e.g. AuthorizationExceptionServerException
- If the server refuses upload (e.g. because only getPermittedWorkflows()
are allowed)org.apache.taverna.server.client.TavernaServer.ServerException
public Run createWorkflowRun(URI t2flowUri) throws TavernaServer.ClientException, org.apache.taverna.server.client.TavernaServer.ServerException
The returned Run
be configured (e.g. with
Run.setInput(String, String)
) before invoking it
with Run.start()
.
t2flowUri
- URI of workflow to run, should have content-type application/vnd.taverna.t2flow+xml
Run
that is Status.Initialized
TavernaServer.ClientException
- If client configuration failed, e.g. AuthorizationExceptionServerException
- If the server refuses the URI (e.g. it could not be retrieved)org.apache.taverna.server.client.TavernaServer.ServerException
Copyright © 2015–2018 The Apache Software Foundation. All rights reserved.