Module: Symbiont::Ready::ClassMethods

Defined in:
lib/symbiont/ready.rb

Instance Method Summary collapse

Instance Method Details

#_ready_validationsObject



18
19
20
# File 'lib/symbiont/ready.rb', line 18

def _ready_validations
  @_ready_validations ||= []
end

#page_ready(&block) ⇒ Object Also known as: page_ready_when



12
13
14
# File 'lib/symbiont/ready.rb', line 12

def page_ready(&block)
  _ready_validations << block
end

#ready_validationsObject



4
5
6
7
8
9
10
# File 'lib/symbiont/ready.rb', line 4

def ready_validations
  if superclass.respond_to?(:ready_validations)
    superclass.ready_validations + _ready_validations
  else
    _ready_validations
  end
end