Add a __toString() method on BSPrinterAbstract
[isso.git] / PrinterAbstract.php
index 08a91abe62b685b42bd161f347c62c78b68f15ae..dddabe2472d71858bcd8ca0f90ac39e3a4621f95 100644 (file)
@@ -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
         *