Class: Cfan122::Config
- Inherits:
-
Object
- Object
- Cfan122::Config
- Includes:
- Singleton
- Defined in:
- lib/cfan122/config.rb
Instance Attribute Summary collapse
-
#domain ⇒ Object
Returns the value of attribute domain.
-
#password ⇒ Object
Returns the value of attribute password.
-
#timeout ⇒ Object
Returns the value of attribute timeout.
-
#username ⇒ Object
Returns the value of attribute username.
Instance Method Summary collapse
-
#initialize ⇒ Config
constructor
A new instance of Config.
- #reset ⇒ Object
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
10 11 12 |
# File 'lib/cfan122/config.rb', line 10 def initialize reset end |
Instance Attribute Details
#domain ⇒ Object
Returns the value of attribute domain.
8 9 10 |
# File 'lib/cfan122/config.rb', line 8 def domain @domain end |
#password ⇒ Object
Returns the value of attribute password.
8 9 10 |
# File 'lib/cfan122/config.rb', line 8 def password @password end |
#timeout ⇒ Object
Returns the value of attribute timeout.
8 9 10 |
# File 'lib/cfan122/config.rb', line 8 def timeout @timeout end |
#username ⇒ Object
Returns the value of attribute username.
8 9 10 |
# File 'lib/cfan122/config.rb', line 8 def username @username end |
Instance Method Details
#reset ⇒ Object
14 15 16 17 18 |
# File 'lib/cfan122/config.rb', line 14 def reset @domain ||= 'http://www.122.gov.cn' @username = nil @password = nil end |