Home | History | Annotate | Download | only in multipart

Lines Matching full:boundary

94 // given MIME boundary.
96 // The boundary is usually obtained from the "boundary" parameter of
99 func NewReader(r io.Reader, boundary string) *Reader {
100 b := []byte("\r\n--" + boundary + "--")
171 // or we find a reason to stop (boundary or read error).
203 // dashBoundary is "--boundary".
204 // nlDashBoundary is "\r\n--boundary" or "\n--boundary", depending on what mode we are in.
205 // The comments below (and the name) assume "\n--boundary", but either is accepted.
206 // total is the number of bytes read out so far. If total == 0, then a leading "--boundary" is recognized.
229 // Search for "\n--boundary".
244 // Otherwise, anything up to the final \n is not part of the boundary
246 // Also if the section from the final \n onward is not a prefix of the boundary,
255 // matchAfterPrefix checks whether buf should be considered to match the boundary.
256 // The prefix is "--boundary" or "\r\n--boundary" or "\n--boundary",
259 // matchAfterPrefix returns +1 if the buffer does match the boundary,
261 // It returns -1 if the buffer definitely does NOT match the boundary,
294 nl []byte // "\r\n" or "\n" (set after seeing first boundary line)
295 nlDashBoundary []byte // nl + "--boundary"
296 dashBoundaryDash []byte // "--boundary--"
297 dashBoundary []byte // "--boundary"
312 // If the buffer ends in "--boundary--" without the
348 // body of the previous part and the boundary line we
350 // end boundary)
360 // isFinalBoundary reports whether line is the final boundary line
362 // It matches `^--boundary--[ \t]*(\r\n)?$`
374 // The boundary delimiter line is then defined as a line
376 // decimal value 45) followed by the boundary parameter