Dear monks,
I bet there must be a CPAN module that does the following:
- You instantiate an object that takes a path to an executable as an argument.
- It connects to the executable's STDIN and STDOUT, internally in the same way one would do using IPC::Open2.
- The object has at least two methods: $obj->send_command('command line interaction') and $obj->return_output for writing to, and reading from the executable's input and output.
- In effect, you'd be able to interact, via these two methods with the executable, while the object, internally, sorts out the details of cloning STDIN & STDOUT, buffering, hairy edge cases.
I'm looking for the kind of functionality that
Statistics::R has to offer, but in a more general & abstracted way. I bet something like that already exists, right? What module am I missing?
Thanks!