Skip to content

Commit de860ef

Browse files
committed
update pkgimport readme
1 parent f064d09 commit de860ef

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

cmd/pkgimport/README.md

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ go generate
2525
```
2626

2727
``` golang
28-
2928
// Code generated by "pkgimport -p mime -i mime -o mime.go"; DO NOT EDIT.
3029
// Install by "go get -u -v github.com/wzshiming/gotype/cmd/pkgimport";
3130
//go:generate pkgimport -p mime -i mime -o mime.go
@@ -36,6 +35,21 @@ import (
3635
origin "mime"
3736
)
3837

38+
// Value
39+
var (
40+
41+
// QEncoding represents the Q-encoding scheme as defined by RFC 2047.
42+
QEncoding = origin.QEncoding
43+
44+
// ErrInvalidMediaParameter is returned by ParseMediaType if
45+
// the media type value was found but there was an error parsing
46+
// the optional parameters
47+
ErrInvalidMediaParameter = origin.ErrInvalidMediaParameter
48+
49+
// BEncoding represents Base64 encoding scheme as defined by RFC 2045.
50+
BEncoding = origin.BEncoding
51+
)
52+
3953
// Type
4054
type (
4155

@@ -46,7 +60,7 @@ type (
4660
WordDecoder = origin.WordDecoder
4761
)
4862

49-
// Declaration
63+
// Function
5064
var (
5165

5266
// TypeByExtension returns the MIME type associated with the file extension ext.
@@ -68,9 +82,6 @@ var (
6882
// Text types have the charset parameter set to "utf-8" by default.
6983
TypeByExtension = origin.TypeByExtension
7084

71-
// QEncoding represents the Q-encoding scheme as defined by RFC 2047.
72-
QEncoding = origin.QEncoding
73-
7485
// ParseMediaType parses a media type value and any optional
7586
// parameters, per RFC 1521. Media types are the values in
7687
// Content-Type and Content-Disposition headers (RFC 2183).
@@ -96,20 +107,11 @@ var (
96107
// nil slice.
97108
ExtensionsByType = origin.ExtensionsByType
98109

99-
// ErrInvalidMediaParameter is returned by ParseMediaType if
100-
// the media type value was found but there was an error parsing
101-
// the optional parameters
102-
ErrInvalidMediaParameter = origin.ErrInvalidMediaParameter
103-
104-
// BEncoding represents Base64 encoding scheme as defined by RFC 2045.
105-
BEncoding = origin.BEncoding
106-
107110
// AddExtensionType sets the MIME type associated with
108111
// the extension ext to typ. The extension should begin with
109112
// a leading dot, as in ".html".
110113
AddExtensionType = origin.AddExtensionType
111114
)
112-
113115
```
114116

115117
## License

0 commit comments

Comments
 (0)