module Loggability::LogClient
Methods to install for objects which call log_to
.
Attributes
log_host_key[RW]
The key of the log host this client targets
Public Instance Methods
inherited( subclass )
click to toggle source
Inheritance hook – set the log host key of subclasses to the same thing as the extended class.
Calls superclass method
# File lib/loggability/logclient.rb, line 22 def inherited( subclass ) super Loggability.log.debug "Setting up subclass %p of %p to log to %p" % [ subclass, self, self.log_host_key ] subclass.log_host_key = self.log_host_key end
log()
click to toggle source
Return the Loggability::Logger object associated with the log host the client is logging to. :TODO: Use delegation for efficiency.
# File lib/loggability/logclient.rb, line 15 def log @__log ||= Loggability[ self ].proxy_for( self ) end