Module: Nem::Configuration
- Included in:
- Nem
- Defined in:
- lib/nem/configuration.rb
Constant Summary collapse
- DEADLINE =
1 hour
3600
Instance Attribute Summary collapse
-
#debug ⇒ Object
Returns the value of attribute debug.
-
#default_deadline ⇒ Object
Returns the value of attribute default_deadline.
-
#default_network ⇒ Object
Returns the value of attribute default_network.
-
#logger ⇒ Object
Returns the value of attribute logger.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#debug ⇒ Object
Returns the value of attribute debug.
7 8 9 |
# File 'lib/nem/configuration.rb', line 7 def debug @debug end |
#default_deadline ⇒ Object
Returns the value of attribute default_deadline.
7 8 9 |
# File 'lib/nem/configuration.rb', line 7 def default_deadline @default_deadline end |
#default_network ⇒ Object
Returns the value of attribute default_network.
7 8 9 |
# File 'lib/nem/configuration.rb', line 7 def default_network @default_network end |
#logger ⇒ Object
Returns the value of attribute logger.
7 8 9 |
# File 'lib/nem/configuration.rb', line 7 def logger @logger end |
Class Method Details
.extended(base) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/nem/configuration.rb', line 11 def self.extended(base) base.logger = Logger.new($stdout).tap { |l| l.level = Logger::INFO } base.debug = false base.default_deadline = DEADLINE base.default_network = :testnet end |
Instance Method Details
#configure {|self| ... } ⇒ Object
26 27 28 |
# File 'lib/nem/configuration.rb', line 26 def configure yield self end |