Module: Operandi

Defined in:
lib/operandi/base.rb,
lib/operandi.rb,
lib/operandi/utils.rb,
lib/operandi/config.rb,
lib/operandi/message.rb,
lib/operandi/version.rb,
lib/operandi/messages.rb,
lib/operandi/callbacks.rb,
lib/operandi/constants.rb,
lib/operandi/collection.rb,
lib/operandi/exceptions.rb,
lib/operandi/dsl/steps_dsl.rb,
lib/operandi/settings/step.rb,
lib/operandi/dsl/validation.rb,
lib/operandi/settings/field.rb,
lib/operandi/dsl/outputs_dsl.rb,
lib/operandi/base_with_context.rb,
lib/operandi/dsl/arguments_dsl.rb,
lib/operandi/concerns/execution.rb,
lib/operandi/concerns/parent_service.rb,
lib/operandi/concerns/state_management.rb,
lib/operandi/rspec/matchers/define_step.rb,
lib/operandi/rspec/matchers/execute_step.rb,
lib/operandi/rspec/matchers/define_output.rb,
lib/operandi/rspec/matchers/have_error_on.rb,
lib/operandi/rspec/matchers/define_argument.rb,
lib/operandi/rspec/matchers/have_warning_on.rb,
lib/operandi/rspec/matchers/trigger_callback.rb,
lib/generators/operandi/install/install_generator.rb,
lib/generators/operandi/service/service_generator.rb

Overview

Base class for all service objects

Defined Under Namespace

Modules: CallbackDsl, Callbacks, Collection, CollectionTypes, Concerns, Dsl, FieldTypes, Generators, RSpec, ReservedNames, Settings, Utils Classes: ArgTypeError, Base, BaseWithContext, Config, Error, FailExecution, InvalidNameError, Message, Messages, MissingTypeError, NoStepsError, ReservedNameError, RuntimeError, StopExecution

Constant Summary collapse

VERSION =
"5.0.0"

Class Method Summary collapse

Class Method Details

.configConfig

Get the global configuration object.

Returns:

  • (Config)

    the configuration instance



23
24
25
# File 'lib/operandi/config.rb', line 23

def config
  @config ||= Config.new
end

.configure {|Config| ... } ⇒ void

This method returns an undefined value.

Configure Operandi with a block.

Examples:

Operandi.configure do |config|
  config.require_arg_type = true
  config.require_output_type = true
  config.use_transactions = false
end

Yields:

  • (Config)

    the configuration object



16
17
18
# File 'lib/operandi/config.rb', line 16

def configure
  yield config
end