Lines Matching refs:part
28 // A Part represents a single part in a multipart body.
29 type Part struct {
55 func (p *Part) FormName() string {
67 // FileName returns the filename parameter of the Part's
69 func (p *Part) FileName() string {
76 func (p *Part) parseContentDisposition() {
102 func newPart(mr *Reader) (*Part, error) {
103 bp := &Part{
120 func (bp *Part) populateHeaders() error {
129 // Read reads the body of a part, after its headers and before the
130 // next part (if any) begins.
131 func (p *Part) Read(d []byte) (n int, err error) {
136 // wrapped *Part, without doing any Transfer-Encoding decoding.
138 p *Part
153 // Look for an immediate empty part without a leading \r\n
163 return 0, fmt.Errorf("multipart: Part Read: %v", err)
202 func (p *Part) Close() error {
213 currentPart *Part
222 // NextPart returns the next part in the multipart or an error.
224 func (r *Reader) NextPart() (*Part, error) {
260 return nil, fmt.Errorf("multipart: expecting a new Part; got line %q", string(line))
269 // body of the previous part and the boundary line we
270 // now expect will follow. (either a new part or the
306 // On the first part, see our lines are ending in \n instead of \r\n
317 // buffer represents an empty part. It is called only if we've not
318 // already read any bytes in this part and checks for the case of MIME
325 // case the whole line is part of the data.