Documentation ¶
Index ¶
- func CanonicalAddr(host string, port int) (addr string)
- func CanonicalHost(host string) (string, error)
- func GenerateResponseErrorString(summary string, err error, detailed bool) string
- func GetAuthKey(token string, timestamp int64) (key string)
- func GetHostFromAddr(addr string) (host string)
- func OkResponse() *http.Response
- func ParseRangeNumbers(rangeStr string) (numbers []int64, err error)
- func RandID() (id string, err error)
- func RandIDWithLen(idLen int) (id string, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CanonicalAddr ¶
func CanonicalHost ¶
canonicalHost strips port from host if present and returns the canonicalized host name.
func GetAuthKey ¶
func GetHostFromAddr ¶
TODO: use "CanonicalHost" func to replace all "GetHostFromAddr" func.
func OkResponse ¶
func ParseRangeNumbers ¶
func RandIDWithLen ¶
RandIDWithLen return a rand string with idLen length.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.