Class: Culpa::AsyncBrickchain

Inherits:
Object
  • Object
show all
Defined in:
lib/culpa/brickchain_helpers.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(envelope, request) ⇒ AsyncBrickchain

Returns a new instance of AsyncBrickchain.



41
42
43
44
45
# File 'lib/culpa/brickchain_helpers.rb', line 41

def initialize(envelope, request)
  @envelope = envelope
  @request = request
  @chs = []
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(sym) ⇒ Object



47
48
49
50
# File 'lib/culpa/brickchain_helpers.rb', line 47

def method_missing(sym)
  @chs << CallHolder.new(sym.to_s, @envelope, @request, true)
  @chs.last
end

Instance Attribute Details

#chsObject (readonly)

Returns the value of attribute chs.



39
40
41
# File 'lib/culpa/brickchain_helpers.rb', line 39

def chs
  @chs
end

#envelopeObject (readonly)

Returns the value of attribute envelope.



38
39
40
# File 'lib/culpa/brickchain_helpers.rb', line 38

def envelope
  @envelope
end