gentleman.v2: Index | Files

package multipart

import ""


Package Files


func Data Uses

func Data(data FormData) p.Plugin

Data creates custom form based on the given form data who can have files and string based fields.

func Fields Uses

func Fields(fields DataFields) p.Plugin

Fields creates a new multipart form based on string based fields.

func File Uses

func File(name string, reader io.Reader) p.Plugin

File creates a new multipart form based on a unique file field from the given io.ReadCloser stream.

func Files Uses

func Files(files []FormFile) p.Plugin

Files creates a multipart form based on files fields.

type DataFields Uses

type DataFields map[string]Values

DataFields represents a map of text based fields.

type FormData Uses

type FormData struct {
    Data  DataFields
    Files []FormFile

FormData represents the supported form fields by file and string data.

type FormFile Uses

type FormFile struct {
    Name   string
    Reader io.Reader

FormFile represents the file form field data.

type Values Uses

type Values []string

Values represents multiple multipart from values.

Package multipart imports 9 packages (graph) and is imported by 7 packages. Updated 2020-02-18. Refresh now. Tools for package owners.