Documentation ¶
Index ¶
- Constants
- func BitAutoString(size int64) string
- func FileName(filename string) string
- func NumberToChineseCapital(number int64) string
- func PhoneAddAreaCode(phone string, countryCode string) string
- func PhoneKeepNumbersOnly(phone string) string
- func PhoneRemoveAreaCode(phone string, countryCode string) string
- type Countries
- type ListParams
- type Resp
- type RespData
Constants ¶
View Source
const ( ContentTypeDownload = `application/force-download` //文件下载 ContentTypeDefault = `text/plain; charset=UTF-8` //文本 ContentTypeJSON = `application/json; charset=UTF-8` //json ContentTypeHTML = `text/html; charset=UTF-8` //HTML ContentTypeXJS = `application/x-javascript;charset=UTF-8` //JavaScript ContentTypeJS = `text/javascript; charset=utf-8` //JavaScript ContentTypeCSS = `text/css; charset=utf-8` //CSS ContentTypeImageJPEG = `image/jpeg` //jpeg图片 ContentTypeImageJPG = `image/jpeg` //jpg图片 ContentTypeImagePNG = `image/png` //png图片 ContentTypeImageWEBP = `image/webp` //webp图片 ContentTypeImageGIF = `image/gif` //gif图片 ContentTypeImageICON = `image/x-icon` //icon图标 ContentTypeImageOctetStream = `application/octet-stream` //八位字节流 )
Variables ¶
This section is empty.
Functions ¶
func BitAutoString ¶ added in v0.0.24
BitAutoString 将字节自动输出成合适的单位内容。
func NumberToChineseCapital ¶ added in v0.0.24
NumberToChineseCapital 数字转成中文大写数字
func PhoneAddAreaCode ¶ added in v0.0.10
PhoneAddAreaCode 给号码添加上+号和区号
func PhoneKeepNumbersOnly ¶ added in v0.0.10
PhoneKeepNumbersOnly 只保留下数字
func PhoneRemoveAreaCode ¶ added in v0.0.10
PhoneRemoveAreaCode 移除号码前面的+号和区号
Types ¶
type Countries ¶ added in v0.0.10
type Countries struct { Code string `json:"code"` AreaCode string `json:"area_code"` Name string `json:"name"` }
func GetCountryInfo ¶ added in v0.0.10
GetCountryInfo 获取指定国家或地区的区号及名称-根据国家或地区代码
type ListParams ¶ added in v0.0.23
Click to show internal directories.
Click to hide internal directories.