Arranges for a stream-like object to be sent to the stdout, stderr or stdin of a Runner. More...
Arranges for a stream-like object to be sent to the stdout, stderr or stdin of a Runner.
Public Member Functions | |
def | __init__ (self, obj) |
Creates a StreamReuser for the specified stream-like object. More... | |
def | copy (self) |
Returns a shallow copy of this object. More... | |
def | to_shell (self) |
Raises NotValidPosixSh to indicate that the stream cannot be represented as POSIX sh. More... | |
def | repr_for_in (self) |
Returns repr(obj) where obj is the given stream-like object. More... | |
def | repr_for_out (self) |
Returns repr(obj) where obj is the given stream-like object. More... | |
![]() | |
def | for_input (self) |
Has no effect. More... | |
def | for_output (self) |
Has no effect. More... | |
def | repr_for_err (self) |
Returns the stderr value. More... | |
Public Attributes | |
obj | |
the stream-like object to reuse. More... | |
def produtil.prog.StreamReuser.__init__ | ( | self, | |
obj | |||
) |
Creates a StreamReuser for the specified stream-like object.
obj | the stream-like object to reuse. |
def produtil.prog.StreamReuser.copy | ( | self | ) |
Returns a shallow copy of this object.
Note that means that the underlying stream object is not copied.
Definition at line 249 of file prog.py.
Referenced by produtil.prog.ImmutableRunner.runner().
def produtil.prog.StreamReuser.repr_for_in | ( | self | ) |
def produtil.prog.StreamReuser.repr_for_out | ( | self | ) |
Returns repr(obj) where obj is the given stream-like object.
Definition at line 266 of file prog.py.
Referenced by produtil.prog.StreamGenerator.repr_for_err().
def produtil.prog.StreamReuser.to_shell | ( | self | ) |
Raises NotValidPosixSh to indicate that the stream cannot be represented as POSIX sh.
produtil.prog.StreamReuser.obj |
the stream-like object to reuse.
Definition at line 246 of file prog.py.
Referenced by produtil.prog.StreamReuser.copy(), produtil.prog.StreamReuser.repr_for_in(), produtil.prog.StreamReuser.repr_for_out(), and produtil.prog.StreamReuser.to_shell().