Class: Groonga::FileLogger
Instance Method Summary collapse
- #fin ⇒ Object
-
#initialize(file_name) ⇒ FileLogger
constructor
A new instance of FileLogger.
- #reopen ⇒ Object
Methods inherited from Logger
#log, log_path, log_path=, query_log_path, query_log_path=
Constructor Details
#initialize(file_name) ⇒ FileLogger
Returns a new instance of FileLogger.
110 111 112 113 114 |
# File 'lib/groonga/logger.rb', line 110 def initialize(file_name) super() @file = nil @file_name = file_name end |
Instance Method Details
#fin ⇒ Object
124 125 126 127 128 129 |
# File 'lib/groonga/logger.rb', line 124 def fin guard do return unless @file @file.close end end |
#reopen ⇒ Object
116 117 118 119 120 121 122 |
# File 'lib/groonga/logger.rb', line 116 def reopen guard do return unless @file @file.close @file = nil end end |