| POE-Filter-ErrorProof documentation | view source | Contained in the POE-Filter-ErrorProof distribution. |
use POE::Filter::ErrorProof; my $wheel = POE::Wheel::ReadWrite->new( Filter => POE::Filter::ErrorProof->new(POE::Filter::Something->new()), );
This module is a wrapper around other POE::Filters. I made this module when I noticed POE::Filter::XML would die() when non-XML input was given to it. The author of the module wasn't there, so I had to bring up a solution. You can use this module if you use a POE::Filter that might die if something bad happens. This Filter does nothing more than giving through the input in eval blocks.
POE::Filter::ErrorProof->new(); # Create a POE::Filter::ErrorProof with a POE::Filter::Stream in it POE::Filter::ErrorProof->new(POE::Filter::XML->new()); # Do the same but with a POE::Filter::XML POE::Filter::ErrorProof->new(POE::Filter::XML->new(), 1); # Do the same, but output errors on STDERR POE::Filter::ErrorProof->new(POE::Filter::XML->new(), $socket); # Do the same, but output errors on this socket $wheel = POE::Wheel::ReadWrite->new( .... ); POE::Filter::ErrorProof->new(POE::Filter::XML->new(), $wheel); # Output errors to this wheel
Sjors Gielen, <sjorsgielen@gmail.com>
| POE-Filter-ErrorProof documentation | view source | Contained in the POE-Filter-ErrorProof distribution. |