Class: Groonga::CallbackLogger
Instance Method Summary
collapse
Methods inherited from Logger
log_path, log_path=, query_log_path, query_log_path=
Constructor Details
Returns a new instance of CallbackLogger.
145
146
147
148
|
# File 'lib/groonga/logger.rb', line 145
def initialize(callback)
super()
@callback = callback
end
|
Instance Method Details
162
163
164
165
166
|
# File 'lib/groonga/logger.rb', line 162
def fin
guard do
@callback.call(:fin)
end
end
|
#log(level, timestamp, title, message, location) ⇒ Object
150
151
152
153
154
|
# File 'lib/groonga/logger.rb', line 150
def log(level, timestamp, title, message, location)
guard do
@callback.call(:log, level, timestamp, title, message, location)
end
end
|
156
157
158
159
160
|
# File 'lib/groonga/logger.rb', line 156
def reopen
guard do
@callback.call(:reopen)
end
end
|