#[non_exhaustive]pub enum SyntaxError {
Show 20 variants
InvalidContentType,
MissingBoundary,
DuplicateBoundary,
InvalidBoundary,
NoInitialDelimiter,
BoundaryInContent,
BareLineFeed,
MalformedHeaderLine,
HeaderFolding,
InvalidHeaderName,
ControlInHeader,
MissingContentDisposition,
DuplicateHeader,
NotFormData,
MissingName,
EmptyName,
DuplicateParameter,
MalformedParameter,
AmbiguousQuote,
Truncated,
}Expand description
What part of the grammar the input broke.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
InvalidContentType
A Content-Type value (of the request or of a part) is malformed.
MissingBoundary
multipart/form-data without a boundary parameter.
DuplicateBoundary
Two boundary parameters.
InvalidBoundary
A boundary that is empty, longer than 70 bytes, has a byte outside
RFC 2046 bchars, or ends with a space.
NoInitialDelimiter
The body ended without any delimiter.
BoundaryInContent
A full delimiter followed by something other than --, padding, or
CRLF; or writer data that contains the delimiter.
BareLineFeed
LF without CR where CRLF is required.
MalformedHeaderLine
A part header line without a colon.
HeaderFolding
A folded part header line.
InvalidHeaderName
A part header name that is not a token, or has whitespace before the colon.
ControlInHeader
A control byte other than HTAB in a part header value.
MissingContentDisposition
A part without Content-Disposition.
DuplicateHeader
A known part header given twice.
NotFormData
A Content-Disposition type other than form-data.
MissingName
A Content-Disposition without name.
EmptyName
An empty name.
DuplicateParameter
A parameter given twice.
MalformedParameter
Malformed parameters (or more than 16 on one header).
AmbiguousQuote
A quoted parameter value that contains \".
Truncated
The body ended before the close delimiter.