Parent

Methods

Files

Lumberjack::Device::LogFile

This is a logging device that appends log entries to a file.

Attributes

path[R]

The absolute path of the file being logged to.

Public Class Methods

new(path, options = {}) click to toggle source

Create a logger to the file at path. Options are passed through to the Writer constructor.

# File lib/lumberjack/device/log_file.rb, line 11
def initialize(path, options = {})
  @path = File.expand_path(path)
  FileUtils.mkdir_p(File.dirname(@path))
  super(File.new(@path, 'a', :encoding => "ascii-8bit"), options)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.