Log::Dispatch::Null - Object that accepts messages and does nothing


Log-Dispatch documentation Contained in the Log-Dispatch distribution.

Index


Code Index:

NAME

Top

Log::Dispatch::Null - Object that accepts messages and does nothing

VERSION

Top

version 2.29

SYNOPSIS

Top

  use Log::Dispatch;

  my $null = Log::Dispatch->new( outputs => [ ['Null'] ] );

  $null->emerg( "I've fallen and I can't get up" );

DESCRIPTION

Top

This class provides a null logging object. Messages can be sent to the object but it does nothing with them.

AUTHOR

Top

Dave Rolsky <autarch@urth.org>

COPYRIGHT AND LICENSE

Top


Log-Dispatch documentation Contained in the Log-Dispatch distribution.

package Log::Dispatch::Null;
BEGIN {
  $Log::Dispatch::Null::VERSION = '2.29';
}

use strict;
use warnings;

use Log::Dispatch::Output;

use base qw( Log::Dispatch::Output );

sub new {
    my $proto = shift;
    my $class = ref $proto || $proto;

    my $self = bless {}, $class;

    $self->_basic_init(@_);

    return $self;
}

sub log_message { }

1;

# ABSTRACT: Object that accepts messages and does nothing




__END__