Module: Lev

Defined in:
lib/lev.rb,
lib/lev/error.rb,
lib/lev/errors.rb,
lib/lev/handler.rb,
lib/lev/outputs.rb,
lib/lev/routine.rb,
lib/lev/version.rb,
lib/lev/utilities.rb,
lib/lev/handle_with.rb,
lib/lev/term_mapper.rb,
lib/lev/form_builder.rb,
lib/lev/memory_store.rb,
lib/lev/active_job/base.rb,
lib/lev/error_transferer.rb,
lib/lev/error_translator.rb,
lib/lev/transaction_isolation.rb,
lib/lev/active_job/configured_job.rb

Defined Under Namespace

Modules: ActiveJob, HandleWith, Handler, Routine, Utilities Classes: AbstractMethodCalled, AlgorithmError, Configuration, Error, ErrorTransferer, ErrorTranslator, Errors, FatalError, FormBuilder, IllegalArgument, IsolationMismatch, MemoryStore, NullStatus, Outputs, Paramifier, SecurityTransgression, TermMapper, TransactionIsolation

Constant Summary collapse

VERSION =
'12.1.0'

Class Method Summary collapse

Class Method Details

.after_initializeObject



55
56
57
# File 'lib/lev.rb', line 55

def after_initialize
  require 'lev/active_job'
end

.configurationObject



51
52
53
# File 'lib/lev.rb', line 51

def configuration
  @configuration ||= Configuration.new
end

.configure {|configuration| ... } ⇒ Object

Configuration machinery.

To configure Lev, put the following code in your applications initialization logic (eg. in the config/initializers in a Rails app)

Lev.configure do |config|
  config.form_error_class = 'fancy_error'
  ...
end

Yields:



46
47
48
49
# File 'lib/lev.rb', line 46

def configure
  yield configuration
  after_initialize
end