escpos-php
 All Classes Namespaces Functions Variables Pages
Public Member Functions | Protected Attributes | List of all members
Mike42\Escpos\PrintConnectors\FilePrintConnector Class Reference
Inheritance diagram for Mike42\Escpos\PrintConnectors\FilePrintConnector:
Inheritance graph
[legend]
Collaboration diagram for Mike42\Escpos\PrintConnectors\FilePrintConnector:
Collaboration graph
[legend]

Public Member Functions

 __construct ($filename)
 
 __destruct ()
 
 finalize ()
 
 read ($len)
 
 write ($data)
 

Protected Attributes

 $fp
 

Detailed Description

PrintConnector for passing print data to a file.

Constructor & Destructor Documentation

Mike42\Escpos\PrintConnectors\FilePrintConnector::__construct (   $filename)

Construct new connector, given a filename

Parameters
string$filename
Mike42\Escpos\PrintConnectors\FilePrintConnector::__destruct ( )

Print connectors should cause a NOTICE if they are deconstructed when they have not been finalized.

Implements Mike42\Escpos\PrintConnectors\PrintConnector.

Member Function Documentation

Mike42\Escpos\PrintConnectors\FilePrintConnector::finalize ( )

Close file pointer

Implements Mike42\Escpos\PrintConnectors\PrintConnector.

Mike42\Escpos\PrintConnectors\FilePrintConnector::read (   $len)

Read data from the printer.

Parameters
string$lenLength of data to read.
Returns
Data read from the printer, or false where reading is not possible.

Implements Mike42\Escpos\PrintConnectors\PrintConnector.

Mike42\Escpos\PrintConnectors\FilePrintConnector::write (   $data)

Write data to the file

Parameters
string$data

Implements Mike42\Escpos\PrintConnectors\PrintConnector.

Member Data Documentation

resource Mike42\Escpos\PrintConnectors\FilePrintConnector::$fp
protected

The file pointer to send data to.


The documentation for this class was generated from the following file: