Documentation ¶
Overview ¶
Package upload provides functions for dealing with uploading files in a fast and safe way
Index ¶
Constants ¶
View Source
const (
// Class is an identifier for the UploadedFile class in Lua
Class = "UploadedFile"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type UploadedFile ¶
type UploadedFile struct {
// contains filtered or unexported fields
}
UploadedFile represents a file that has been uploaded but not yet been written to file.
func New ¶
New creates a struct that is used for accepting an uploaded file
The client will send all the data, if the data is over the given size, if the Content-Length is wrongly set to a value below the the uploadLimit. However, the buffer and memory usage will not grow despite this.
uploadLimit is in bytes.
Note that the client may appear to keep sending the file even when the server has stopped receiving it, for files that are too large.
Click to show internal directories.
Click to hide internal directories.