Class: Podium::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/podium/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



7
8
9
# File 'lib/podium/configuration.rb', line 7

def initialize
  @podlets = {}
end

Instance Attribute Details

#name_to_urlObject



15
16
17
# File 'lib/podium/configuration.rb', line 15

def name_to_url
  @name_to_url || ->(name) { raise "name_to_url not configured. Set name_to_url in podium configuration." }
end

#podletsObject (readonly)

Returns the value of attribute podlets.



3
4
5
# File 'lib/podium/configuration.rb', line 3

def podlets
  @podlets
end

Instance Method Details

#register(name, url = nil) ⇒ Object



11
12
13
# File 'lib/podium/configuration.rb', line 11

def register(name, url = nil)
  @podlets[name] = url
end