Class: Log4r::RemoteOutputter
- Includes:
- ROMPClient
- Defined in:
- lib/log4r/outputter/remoteoutputter.rb
Overview
See log4r/logserver.rb
Instance Attribute Summary
Attributes inherited from Outputter
Instance Method Summary collapse
-
#flush ⇒ Object
Call flush to send any remaining LogEvents to the remote server.
-
#initialize(*args) ⇒ RemoteOutputter
constructor
A new instance of RemoteOutputter.
Methods inherited from Outputter
[], []=, each, each_outputter, #only_at, stderr, stdout
Constructor Details
#initialize(*args) ⇒ RemoteOutputter
Returns a new instance of RemoteOutputter.
9 10 11 12 13 14 15 |
# File 'lib/log4r/outputter/remoteoutputter.rb', line 9 def initialize(_name, hash={}) super(_name, hash) @uri = (hash[:uri] or hash['uri']) @buffsize = (hash[:buffsize] or hash['buffsize'] or 1).to_i @buff = [] connect end |
Instance Method Details
#flush ⇒ Object
Call flush to send any remaining LogEvents to the remote server.
27 28 29 |
# File 'lib/log4r/outputter/remoteoutputter.rb', line 27 def flush synch { send_buffer } end |