Module: RestMyCase

Defined in:
lib/rest_my_case.rb,
lib/rest_my_case/base.rb,
lib/rest_my_case/errors.rb,
lib/rest_my_case/helpers.rb,
lib/rest_my_case/version.rb,
lib/rest_my_case/validator.rb,
lib/rest_my_case/judge/base.rb,
lib/rest_my_case/trial/case.rb,
lib/rest_my_case/config/base.rb,
lib/rest_my_case/trial/court.rb,
lib/rest_my_case/context/base.rb,
lib/rest_my_case/config/general.rb,
lib/rest_my_case/defense_attorney/base.rb,
lib/rest_my_case/accusation_attorneys/base.rb,
lib/rest_my_case/accusation_attorneys/each.rb,
lib/rest_my_case/accusation_attorneys/custom.rb,
lib/rest_my_case/accusation_attorneys/errors.rb,
lib/rest_my_case/accusation_attorneys/format.rb,
lib/rest_my_case/accusation_attorneys/length.rb,
lib/rest_my_case/accusation_attorneys/presence.rb,
lib/rest_my_case/accusation_attorneys/numericality.rb,
lib/rest_my_case/accusation_attorneys/helper_methods.rb

Defined Under Namespace

Modules: AccusationAttorneys, Config, Context, DefenseAttorney, Errors, Helpers, Judge, Trial Classes: Base, Validator

Constant Summary collapse

VERSION =
'1.7.6'

Class Method Summary collapse

Class Method Details

.configObject



33
34
35
# File 'lib/rest_my_case.rb', line 33

def self.config
  @config ||= Config::General.new
end

.configure {|config| ... } ⇒ Object

Yields:



29
30
31
# File 'lib/rest_my_case.rb', line 29

def self.configure
  yield config
end

.get_config(attribute, use_case) ⇒ Object



41
42
43
# File 'lib/rest_my_case.rb', line 41

def self.get_config(attribute, use_case)
  config.get(attribute, use_case)
end

.reset_configObject



37
38
39
# File 'lib/rest_my_case.rb', line 37

def self.reset_config
  @config = Config::General.new
end