Class: MooMoo::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/moo_moo/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



12
13
14
15
16
17
18
# File 'lib/moo_moo/config.rb', line 12

def initialize
  @host     = default_option("host") || 'horizon.opensrs.net'
  @key      = default_option("key")
  @username = default_option("username")
  @password = default_option("password")
  @port     = default_option("port")
end

Instance Attribute Details

#hostObject

Returns the value of attribute host.



5
6
7
# File 'lib/moo_moo/config.rb', line 5

def host
  @host
end

#keyObject

Returns the value of attribute key.



6
7
8
# File 'lib/moo_moo/config.rb', line 6

def key
  @key
end

#loggerObject

Returns the value of attribute logger.



10
11
12
# File 'lib/moo_moo/config.rb', line 10

def logger
  @logger
end

#passwordObject

Returns the value of attribute password.



8
9
10
# File 'lib/moo_moo/config.rb', line 8

def password
  @password
end

#portObject

Returns the value of attribute port.



9
10
11
# File 'lib/moo_moo/config.rb', line 9

def port
  @port
end

#usernameObject

Returns the value of attribute username.



7
8
9
# File 'lib/moo_moo/config.rb', line 7

def username
  @username
end