WWW::SFDC::Role::Exception - Exception role for WWW::SFDC libraries
version 0.36
package MyException; use Moo; with 'WWW::SFDC::Role::Exception'; has 'something', is => 'ro', default => 'value'; package MAIN; # Simple: MyException->throw(message => 'Something bad happened!'); # More complex: my $e = MyException->new(message => 'Something bad happened!'); print $e; # Something bad happened! (not HASH(...)) eval { $e->throw(); } print $@->something; # value
The exception message. When this object is stringified, this will be the value returned.
This will log the message using Log4perl then die with itself as the error value. This enables catching the error and determining whether it's recoverable, or whether the values need using. This is intended for doing things like getting the debug log from a failed ExecuteAnonymous, or unit test results from a failed deployment.
Please report any bugs or feature requests at https://github.com/sophos/WWW-SFDC/issues.
You can find documentation for this module with the perldoc command.
perldoc WWW::SFDC::Role::Exception
You can also look for information at https://github.com/sophos/WWW-SFDC
Alexander Brett <alexander.brett@sophos.com> http://alexander-brett.co.uk
This software is Copyright (c) 2015 by Sophos Limited https://www.sophos.com/.
This is free software, licensed under:
The MIT (X11) License
The full text of the license can be found in the LICENSE file included with this distribution.
To install WWW::SFDC, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WWW::SFDC
CPAN shell
perl -MCPAN -e shell install WWW::SFDC
For more information on module installation, please visit the detailed CPAN module installation guide.