Sha256: 45270e2c19c944c0b10a720947c1121690dd346efdb1515965a73768a472c4a0

Contents?: true

Size: 966 Bytes

Versions: 3

Compression:

Stored size: 966 Bytes

Contents

require 'hashdiff'

module Legion
  module Extensions
    module Actors
      module Base
        include Legion::Extensions::Helpers::Lex

        def runner
          Legion::Runner.run(runner_class: runner_class, function: function, check_subtask: check_subtask?, generate_task: generate_task?)
        rescue StandardError => e
          Legion::Logging.error e.message
          Legion::Logging.error e.backtrace
        end

        def manual
          runner_class.send(runner_function, **args)
        rescue StandardError => e
          Legion::Logging.error e.message
          Legion::Logging.error e.backtrace
        end

        def function
          nil
        end

        def use_runner?
          true
        end

        def args
          {}
        end

        def check_subtask?
          true
        end

        def generate_task?
          false
        end

        def enabled?
          true
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
legionio-0.3.2 lib/legion/extensions/actors/base.rb
legionio-0.3.1 lib/legion/extensions/actors/base.rb
legionio-0.3.0 lib/legion/extensions/actors/base.rb