NAME
Mojo::Upload - Upload
SYNOPSIS
use Mojo::Upload;
my $upload = Mojo::Upload->new;
print $upload->filename;
$upload->copy_to('/foo/bar.txt');
DESCRIPTION
Mojo::Upload is a container for uploads.
ATTRIBUTES
file
my $file = $upload->file;
$upload = $upload->file(Mojo::File->new);
filename
my $filename = $upload->filename;
$upload = $upload->filename('foo');
file_length
my $length = $upload->file_length;
headers
my $headers = $upload->headers;
$upload = $upload->headers(Mojo::Headers->new);
METHODS
Mojo::Upload inherits all methods from Mojo::Base and implements the following new ones.
copy_to
$upload = $upload->copy_to('/foo/bar/baz.txt');
slurp
my $content = $upload->slurp;