Debian Codegraph @

types/type.go

raw symbols SCIP
1 package types
2
3 // Type represents a file MIME type and its extension
4 type Type struct {
5 MIME MIME
6 Extension string
7 }
8
9 // NewType creates a new Type
10 func NewType(ext, mime string) Type {
11 t := Type{
12 MIME: NewMIME(mime),
13 Extension: ext,
14 }
15 return Add(t)
16 }