public function flush() {
        $this->outputStarted = true;

        $files = $this->files;
        $output = $this->output;

        $this->files = array();
        $this->output = '';

        if ($this->flushHandler !== null) {
            call_user_func($this->flushHandler, array(
                    'files' => $files,
                    'output' => $output
                )
            );
        }
    }