func (form *FormData) Paths(extensions []string, target *[]string) *FormData {
	return form.paths(extensions, target)
}
Paths binds the absolute paths of form data files, according to a list of
file extensions, to a string slice variable.

var paths []string

ctx.FormData().Paths([]string{".txt"}, &paths)
package api
import (
	"fmt"
	"io/ioutil"
	"net/http"
	"path/filepath"
	"sort"
	"strconv"
	"strings"
	"time"
	"go.uber.org/multierr"
)
type FormData struct {
	values map[string][]string
	files  map[string]string
	errors error
}
func (form FormData) Validate() error {
	if form.errors == nil {
		return nil
	}
	return WrapError(
		form.errors,
		NewSentinelHTTPError(http.StatusBadRequest, fmt.Sprintf("Invalid form data: %s", form.errors)),
	)
}
func (form *FormData) String(key string, target *string, defaultValue string) *FormData {
	return form.mustValue(key, target, defaultValue)
}
func (form *FormData) MandatoryString(key string, target *string) *FormData {
	return form.mustMandatoryValue(key, target)
}
func (form *FormData) Bool(key string, target *bool, defaultValue bool) *FormData {
	return form.mustValue(key, target, defaultValue)
}
func (form *FormData) MandatoryBool(key string, target *bool) *FormData {
	return form.mustMandatoryValue(key, target)
}
func (form *FormData) Int(key string, target *int, defaultValue int) *FormData {
	return form.mustValue(key, target, defaultValue)
}
func (form *FormData) MandatoryInt(key string, target *int) *FormData {
	return form.mustMandatoryValue(key, target)
}
func (form *FormData) Float64(key string, target *float64, defaultValue float64) *FormData {
	return form.mustValue(key, target, defaultValue)
}
func (form *FormData) MandatoryFloat64(key string, target *float64) *FormData {
	return form.mustMandatoryValue(key, target)
}
func (form *FormData) Duration(key string, target *time.Duration, defaultValue time.Duration) *FormData {
	return form.mustValue(key, target, defaultValue)
}
func (form *FormData) MandatoryDuration(key string, target *time.Duration) *FormData {
	return form.mustMandatoryValue(key, target)
}
func (form *FormData) Custom(key string, assign func(value string) error) *FormData {
	var value string
	form.mustValue(key, &value, "")
	err := assign(value)
	if err != nil {
		form.append(
			fmt.Errorf("form value '%s' is invalid (got '%s', resulting to %w)", key, value, err),
		)
	}
	return form
}
func (form *FormData) MandatoryCustom(key string, assign func(value string) error) *FormData {
	var value string
	form.mustMandatoryValue(key, &value)
	if value == "" {
		return form
	}
	err := assign(value)
	if err != nil {
		form.append(
			fmt.Errorf("form value '%s' is invalid (got '%s', resulting to %w)", key, value, err),
		)
	}
	return form
}
func (form *FormData) Path(filename string, target *string) *FormData {
	return form.path(filename, target)
}
func (form *FormData) MandatoryPath(filename string, target *string) *FormData {
	return form.mandatoryPath(filename, target)
}
func (form *FormData) Content(filename string, target *string, defaultValue string) *FormData {
	var path string
	form.path(filename, &path)
	if path == "" {
		*target = defaultValue
		return form
	}
	return form.readFile(path, filename, target)
}
func (form *FormData) MandatoryContent(filename string, target *string) *FormData {
	var path string
	form.mandatoryPath(filename, &path)
	if path == "" {
		return form
	}
	return form.readFile(path, filename, target)
}