contenttype

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 28, 2018 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContentType

type ContentType struct {
	TopLevelType string
	SubType      string
	Suffix       string
	Parameters   map[string]string
}

func ParseContentType

func ParseContentType(contenttype string) (ContentType, error)

func (*ContentType) Equals

func (contenttype *ContentType) Equals(other ContentType) bool

func (*ContentType) FilterParameters

func (contenttype *ContentType) FilterParameters(parameters map[string]bool)

func (*ContentType) String

func (contenttype *ContentType) String() string

type Filter

type Filter func(contenttype ContentType) bool

func NewFilterContains

func NewFilterContains(partialMimeType string) Filter

func NewFilterEquals

func NewFilterEquals(TopLevelType, SubType, Suffix string) Filter

func NewFilterOr

func NewFilterOr(contentTypeFilterList []Filter) Filter

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL