Class: Hakuban::TagExposeContractBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/hakuban/exchange.rb

Instance Method Summary collapse

Constructor Details

#initialize(exchange, descriptor) ⇒ TagExposeContractBuilder

Returns a new instance of TagExposeContractBuilder.



101
102
103
104
# File 'lib/hakuban/exchange.rb', line 101

def initialize(exchange, descriptor)
  @exchange, @descriptor = exchange, descriptor
  @capacity = 1
end

Instance Method Details

#build(&block) ⇒ Object



111
112
113
# File 'lib/hakuban/exchange.rb', line 111

def build(&block)
  TagExposeContract.send(:new, @exchange, @descriptor, @capacity, &block)
end

#with_capacity(capacity) ⇒ Object



106
107
108
109
# File 'lib/hakuban/exchange.rb', line 106

def with_capacity(capacity)
  @capacity = capacity
  self
end