Module: TavernaPlayer

Defined in:
lib/taverna-player.rb,
lib/taverna_player/engine.rb,
lib/taverna_player/worker.rb,
lib/taverna_player/version.rb,
app/models/taverna_player/run.rb,
lib/taverna_player/model_proxy.rb,
lib/taverna_player/concerns/zip.rb,
lib/taverna_player/port_renderer.rb,
lib/taverna_player/concerns/utils.rb,
app/models/taverna_player/run_port.rb,
app/models/taverna_player/workflow.rb,
lib/generators/templates/models/run.rb,
lib/taverna_player/concerns/callback.rb,
app/models/taverna_player/interaction.rb,
app/helpers/taverna_player/runs_helper.rb,
lib/taverna_player/concerns/models/run.rb,
lib/generators/templates/models/run_port.rb,
lib/generators/templates/models/workflow.rb,
lib/generators/taverna_player/job_generator.rb,
lib/taverna_player/concerns/models/run_port.rb,
lib/taverna_player/concerns/models/workflow.rb,
app/models/taverna_player/service_credential.rb,
app/helpers/taverna_player/application_helper.rb,
lib/generators/taverna_player/views_generator.rb,
lib/taverna_player/concerns/models/input_port.rb,
app/controllers/taverna_player/runs_controller.rb,
lib/generators/taverna_player/models_generator.rb,
lib/taverna_player/concerns/models/output_port.rb,
lib/generators/taverna_player/install_generator.rb,
lib/generators/taverna_player/callbacks_generator.rb,
lib/generators/taverna_player/renderers_generator.rb,
app/controllers/taverna_player/job_queue_controller.rb,
app/controllers/taverna_player/workflows_controller.rb,
lib/generators/taverna_player/controllers_generator.rb,
lib/generators/templates/controllers/runs_controller.rb,
app/controllers/taverna_player/application_controller.rb,
lib/taverna_player/concerns/controllers/runs_controller.rb,
lib/generators/templates/controllers/job_queue_controller.rb,
lib/generators/templates/controllers/workflows_controller.rb,
lib/taverna_player/concerns/controllers/job_queue_controller.rb,
lib/taverna_player/concerns/controllers/workflows_controller.rb,
app/controllers/taverna_player/service_credentials_controller.rb,
lib/generators/templates/controllers/service_credentials_controller.rb,
lib/taverna_player/concerns/controllers/service_credentials_controller.rb

Overview


Copyright © 2013 The University of Manchester, UK.

BSD Licenced. See LICENCE.rdoc for details.

Taverna Player was developed in the BioVeL project, funded by the European Commission 7th Framework Programme (FP7), through grant agreement number 283359.

Author: Robert Haines


Defined Under Namespace

Modules: ApplicationHelper, Concerns, Generators, RunsHelper Classes: ApplicationController, Engine, Interaction, JobQueueController, ModelProxy, PortRenderer, Run, RunPort, RunsController, ServiceCredential, ServiceCredentialsController, Worker, Workflow, WorkflowsController

Constant Summary collapse

VERSION =
"0.11.0"
@@workflow_proxy =
ModelProxy.new("TavernaPlayer::Workflow", [:file, :title, :inputs])
@@user_proxy =
nil
@@current_user_callback =
nil
@@port_renderer =
PortRenderer.new
@@file_store =
":rails_root/public/system"
@@admin_scope =
""
@@server_poll_interval =
5
@@server_retry_interval =
10
@@server_connection_error_retries =
5
@@server_connection =
T2Server::DefaultConnectionParameters.new
@@job_queue_name =
"player"
@@pre_run_callback =
nil
@@post_run_callback =
nil
@@run_cancelled_callback =
nil
@@run_failed_callback =
nil

Class Method Summary collapse

Class Method Details

.port_renderers {|@@port_renderer| ... } ⇒ Object

:call-seq:

port_renderers {|renderer| ...}

Set up the renderers for each MIME type that you want to be able to show in the browser. In most cases the supplied defaults will be sufficient.

See the taverna_player initializer for more information.

Yields:

  • (@@port_renderer)


104
105
106
# File 'lib/taverna-player.rb', line 104

def self.port_renderers
  yield @@port_renderer if block_given?
end

.setup {|_self| ... } ⇒ Object

:call-seq:

setup {|config| ...}

Yield this configuration class so that Taverna Player can be set up.

See the taverna_player initializer for more information.

Yields:

  • (_self)

Yield Parameters:

  • _self (TavernaPlayer)

    the object that the method was called on



158
159
160
# File 'lib/taverna-player.rb', line 158

def self.setup
  yield self
end

.user_model_proxy=(user_class) ⇒ Object

:call-seq:

user_model_proxy = user_class

Set up a proxy to the main application’s user model if it has one. The class name should be supplied as a string, e.g. “User”.

See the taverna_player initializer for more information.



73
74
75
# File 'lib/taverna-player.rb', line 73

def self.user_model_proxy=(user_class)
  @@user_proxy = ModelProxy.new(user_class)
end

.workflow_model_proxy(workflow_class) {|@@workflow_proxy| ... } ⇒ Object

:call-seq:

workflow_model_proxy = workflow_class
workflow_model_proxy(workflow_class) {|proxy| ...}

Set up a proxy to the main application’s workflow model. The class name should be supplied as a string, e.g. “Workflow”.

See the taverna_player initializer for more information.

Yields:

  • (@@workflow_proxy)


50
51
52
53
# File 'lib/taverna-player.rb', line 50

def self.workflow_model_proxy(workflow_class)
  @@workflow_proxy = ModelProxy.new(workflow_class, [:file, :title, :inputs])
  yield @@workflow_proxy if block_given?
end

.workflow_model_proxy=(workflow_class) ⇒ Object

:stopdoc:



56
57
58
# File 'lib/taverna-player.rb', line 56

def self.workflow_model_proxy=(workflow_class)
  TavernaPlayer.workflow_model_proxy(workflow_class)
end