Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dict ¶
type Dict map[string]interface{}
对 map 字段 进行 url 参数拼接
- 参考 标准库 "net/url" 的 url.Values 实现
TODO:
针对 encode() 特别说明:
1. 对于 嵌套 struct 的数据类型, 会在首层迭代时, 转换成 json string, 再 encode()
2. 这里对 interface{} 数据类型的断言, 是不完善的, 暂时不处理
type StringDict ¶
对 map 字段 进行 url 参数拼接
- 参考 标准库 "net/url" 的 url.Values 实现
func (StringDict) Del ¶
func (m StringDict) Del(key string)
Del deletes the values associated with key.
func (StringDict) Encode ¶
func (m StringDict) Encode() string
Encode encodes the values into “URL encoded” form ("bar=baz&foo=quux") sorted by key.
func (StringDict) Get ¶
func (m StringDict) Get(key string) string
func (StringDict) Set ¶
func (m StringDict) Set(key string, value string)
Click to show internal directories.
Click to hide internal directories.