module AdobeConnect::Config

Public: Manage configuration for AdobeConnect::Service objects, like username/password/domain.

Public Class Methods

[](key) click to toggle source

Public: Fetch a single key value from the current settings.

key - The key to fetch.

Examples

AdobeConnect::Config[:username] #=> 'user@example.com'

Returns the value of the key (usually a string).

# File lib/adobe_connect/config.rb, line 45
def [](key)
  @settings[key]
end
[]=(key, value) click to toggle source

Public: Set a single key's value.

key - The name of the key to set. value - The value to set the key to.

Examples

AdobeConnect::Config[:username] = 'user@example.com'

Returns nothing.

# File lib/adobe_connect/config.rb, line 59
def []=(key, value)
  @settings[key] = value
end
declare(&block) click to toggle source

Public: Declare default Connect settings using a block.

&block - A block with configuration options.

Examples

AdobeConnect::Config.declare do
        username 'user@example.com'
        password 'password'
        domain   'http://connect.example.com'
end

Returns nothing.

# File lib/adobe_connect/config.rb, line 32
def declare(&block)
  instance_eval(&block)
end
merge(settings) click to toggle source

Public: Merge the given settings hash into the current settings.

settings - A hash of setting options.

Returns nothing.

# File lib/adobe_connect/config.rb, line 15
def merge(settings)
  @settings.merge(settings)
end
settings() click to toggle source

Public: Getter for the internal settings hash.

Returns a hash.

# File lib/adobe_connect/config.rb, line 66
def settings; @settings; end