Public Member Functions | |
receive (&$data) | |
attachSink (Filter &$sink) | |
getProcessTime () | |
getMemoryUsage () | |
Protected Member Functions | |
__construct ($inType, $outType) | |
process (&$data) | |
send (&$data) | |
Private Attributes | |
$inDataType | |
$outDataType | |
$sinks | |
$timeStart | |
$timeEnd | |
$memStart | |
$memEnd |
Filter::__construct | ( | $ | inType, | |
$ | outType | |||
) | [protected] |
Default constructor. Child classes have to call it to set data types.
$inType | Type for incoming data. | |
$outType | Type for outgoing data. |
Filter::receive | ( | &$ | data | ) | [final] |
Consume incoming data. This function checks the type of the data and in case of correct type delegates the
$data | Incoming data. |
Filter::process | ( | &$ | data | ) | [abstract, protected] |
Do something with the data. This function has to be implemented by child classes. It gets the incoming data and should produce some output by calling the send() function
Reimplemented in InputObj, OutputPngRaster, OutputPngVector, OutputSvg, Rasterization, Renderer, RendererBackFaceCulling, and RendererLighting.
Filter::send | ( | &$ | data | ) | [final, protected] |
Send the data produced by this filter to all sinks.
$data | Data which should be sent. |
Filter::attachSink | ( | Filter &$ | sink | ) | [final] |
Add a new sink to this filter.
$sink | Additional sink. |
Filter::getProcessTime | ( | ) | [final] |
Return the time it took to process the data.
Filter::getMemoryUsage | ( | ) | [final] |
Return the amount of memory which was allocated and not freed.
Filter::$inDataType [private] |
Type of incoming data.
Filter::$outDataType [private] |
Type of outgoing data.
Filter::$sinks [private] |
List of sinks which will be fed with data leaving this filter.
Filter::$timeStart [private] |
Stores time at which processing begins.
Filter::$timeEnd [private] |
Stores time at which processing ends.
Filter::$memStart [private] |
Stores amount of memory at time at which processing begins.
Filter::$memEnd [private] |
Stores amount of memory at time at which processing ends.