Pipeline::Error::Construction - exception thrown during object construction failure


Pipeline documentation Contained in the Pipeline distribution.

Index


Code Index:

NAME

Top

Pipeline::Error::Construction - exception thrown during object construction failure

SYNOPSIS

Top

  use Pipeline::Error::Construction;

  throw Pipeline::Error::Construction;

DESCRIPTION

Top

Pipeline::Error::Construction inherits from Error and will be thrown by any constructor in the Pipeline module that fails to properly assemble itself.

SEE ALSO

Top

Pipeline::Error::Abstract Error

AUTHOR

Top

James A. Duncan <jduncan@fotango.com>

COPYRIGHT

Top


Pipeline documentation Contained in the Pipeline distribution.

package Pipeline::Error::Construction;

use strict;

use Error;
use base qw( Error );

our $VERSION = "3.12";

sub new {
  my $class = shift;

  my $caller = caller(1);
  my $text = "cannot create object of type $caller";

  local $Error::Depth = $Error::Depth + 1;
  local $Error::Debug = 1;  # Enables storing of stacktrace

  $class->SUPER::new(-text => $text, @_); 
}

1;