Class YARD::Logger
In: lib/yard/logging.rb
Parent: ::Logger

Handles console logging for info, warnings and errors. Uses the stdlib Logger class in Ruby for all the backend logic.

Methods

Attributes

show_backtraces  [W] 

Public Class methods

The logger instance @return [Logger] the logger instance

Creates a new logger

Public Instance methods

Prints the backtrace exc to the logger as error data.

@param [Array<String>] exc the backtrace list @return [void]

Changes the debug level to DEBUG if $DEBUG is set and writes a debugging message.

Sets the logger level for the duration of the block

@example

  log.enter_level(Logger::ERROR) do
    YARD.parse_string "def x; end"
  end

@param [Fixnum] new_level the logger level for the duration of the block.

  values can be found in Ruby's Logger class.

@yield the block with the logger temporarily set to new_level

Warns that the Ruby environment does not support continuations. Applies to JRuby, Rubinius and MacRuby. This warning will only display once per Ruby process.

@deprecated Continuations are no longer needed by YARD 0.8.0+. @return [void]

[Validate]