MCPcopy Create free account
hub / github.com/numpy/numpy / GrabStdout

Class GrabStdout

numpy/distutils/command/config.py:501–516  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

499 return exitcode, output
500
501class GrabStdout:
502
503 def __init__(self):
504 self.sys_stdout = sys.stdout
505 self.data = ''
506 sys.stdout = self
507
508 def write (self, data):
509 self.sys_stdout.write(data)
510 self.data += data
511
512 def flush (self):
513 self.sys_stdout.flush()
514
515 def restore(self):
516 sys.stdout = self.sys_stdout

Callers 1

get_outputMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected