Class: BetfairApiNgRails::Api::Logs::FileLogger
- Inherits:
-
Struct
- Object
- Struct
- BetfairApiNgRails::Api::Logs::FileLogger
- Defined in:
- lib/betfair_api_ng_rails/api/logs/file_logger.rb
Instance Attribute Summary collapse
-
#env ⇒ Object
Returns the value of attribute env.
-
#root ⇒ Object
Returns the value of attribute root.
Instance Method Summary collapse
Instance Attribute Details
#env ⇒ Object
Returns the value of attribute env
4 5 6 |
# File 'lib/betfair_api_ng_rails/api/logs/file_logger.rb', line 4 def env @env end |
#root ⇒ Object
Returns the value of attribute root
4 5 6 |
# File 'lib/betfair_api_ng_rails/api/logs/file_logger.rb', line 4 def root @root end |
Instance Method Details
#write(content) ⇒ Object
5 6 7 8 9 |
# File 'lib/betfair_api_ng_rails/api/logs/file_logger.rb', line 5 def write(content) File.open(file_path, 'a') do |file| file.puts "[#{now_date}] - #{content}" end end |