public static function flushFailed(
        SplFileObject $file,
        Exception $previous = null
    ) {
        return new self(
            sprintf(
                'The file "%s" could not be flushed.',
                $file->getPathname()
            ),
            0,
            $previous
        );
    }