this method is called in response to a request to flush the attached stream such as with fflush or fclose the closing parameter tells you whether the stream is in fact in the process of closing the default action is to simply call return parentflush $ closing your filter may wish to perform additional writes andor cleanup calls prior to or directly after a successful flush 