Proc::Hevy::Reader - A reader pipe implementation for Proc::Hevy
Proc::Heavy::Reader implements a reader pipe that reads data from a child process handle to a provided buffer. This is used when capturing STDOUT and STDERR data from a child process.
STDOUT
STDERR
Creates a new Proc::Hevy::Reader object. $name is a symbolic name for the reader. $buffer is the storage mechanism to be used for data read from the child process. It can either be a simple scalar, an ARRAY reference, a CODE reference or a GLOB reference.
Proc::Hevy::Reader
$name
$buffer
ARRAY
CODE
GLOB
Performs actions suitable when running as part of the child process. This includes re-opening the provided $handle to a filehandle that is created based on the type of storage buffer configured in new(). If no buffer was configured, '/dev/null' is opened for writing.
$handle
new()
'/dev/null'
Performs actions suitable when running as part of the parent process. This includes adding filehandles to the provided $select object that should be monitored for readability.
$select
Performs the actual read from the child process and stores any read data into the storage buffer configured in new(). At EOF, applicable filehandles are closed and removed from the select object used in the call to parent(). Any system errors are considered fatal.
parent()
None are known at this time, but if you find one, please feel free to submit a report to the author.
jason hord <pravus@cpan.org>
Copyright (c) 2009-2014, jason hord
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
To install Proc::Lite, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Proc::Lite
CPAN shell
perl -MCPAN -e shell install Proc::Lite
For more information on module installation, please visit the detailed CPAN module installation guide.