Class: IAuthU::Authenticator::Chained::Builder

Inherits:
Object
  • Object
show all
Defined in:
lib/iauthu/authenticator/chained.rb

Overview

:nodoc:

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeBuilder

Returns a new instance of Builder.



93
94
95
# File 'lib/iauthu/authenticator/chained.rb', line 93

def initialize
  @auth = Chained.new
end

Instance Attribute Details

#authObject (readonly)

Returns the value of attribute auth.



97
98
99
# File 'lib/iauthu/authenticator/chained.rb', line 97

def auth
  @auth
end

Instance Method Details

#use(authenticator = nil, opts = {}, &block) ⇒ Object



99
100
101
102
103
104
# File 'lib/iauthu/authenticator/chained.rb', line 99

def use(authenticator=nil, opts={}, &block)
  if block && !authenticator
    authenticator = block
  end
  @auth.add authenticator, opts
end