| Conditions | 1 |
| Total Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| 1 | from pyprint.Printer import Printer |
||
| 7 | """ |
||
| 8 | |||
| 9 | def __init__(self): |
||
| 10 | """ |
||
| 11 | Creates a new StringPrinter with an empty print string. |
||
| 12 | """ |
||
| 13 | Printer.__init__(self) |
||
| 14 | |||
| 15 | self._string = "" |
||
| 16 | |||
| 17 | def _print(self, output, **kwargs): |
||
| 18 | self._string += output |
||
| 19 | |||
| 20 | def clear(self): |
||
| 21 | """ |
||
| 22 | Clears the print string. |
||
| 23 | """ |
||
| 24 | self._string = "" |
||
| 32 |