public function createUploadedFile(
            StreamInterface $file, 
            int $size = null, 
            int $error = \UPLOAD_ERR_OK, 
            string $clientFilename = null, 
            string $clientMediaType = null
        ): UploadedFileInterface
        {
            if (!$file->isReadable()) {
                throw new \InvalidArgumentException('Temporany resource must be readable');
            }
            $size = (is_null($size)) ? $file->getSize() : $size;
            return new UploadedFile($file, $size, $error, $clientFilename, $clientMediaType); 
        }