https://src.bluestatic.org
/
isso.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Add a __toString() method on BSPrinterAbstract
[isso.git]
/
PrinterAbstract.php
diff --git
a/PrinterAbstract.php
b/PrinterAbstract.php
index 08a91abe62b685b42bd161f347c62c78b68f15ae..dddabe2472d71858bcd8ca0f90ac39e3a4621f95 100644
(file)
--- a/
PrinterAbstract.php
+++ b/
PrinterAbstract.php
@@
-66,6
+66,14
@@
abstract class BSPrinterAbstract
*/
public abstract function paint();
+ /**
+ * To-string method which invokes paint()
+ */
+ public function __toString()
+ {
+ return $this->paint();
+ }
+
/**
* Sets the CSS class to use. Use ":swap:" to alternate
*