mock

package
v1.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 6, 2022 License: Apache-2.0 Imports: 6 Imported by: 2 modules, 3 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	String         = "string"
	Integer        = "integer"
	Float          = "float"
	Boolean        = "boolean"
	Upper          = "upper"
	Lower          = "lower"
	Mobile         = "mobile"
	DigitalLetters = "digital_letters"
	Letters        = "letters"
	Character      = "character"
	List           = "list"
)

数据类型

View Source
const (
	HourStampS  = 3600
	HourStampMs = 3600000
	HourStampNs = 3600000000000
)
View Source
const (
	TimeStamp            = "timestamp"               // 当前时间戳s格式:1587631494(s)
	TimeStampHour        = "timestamp_hour"          // 1小时前时间戳s格式:1587627894(s)
	TimeStampAfterHour   = "timestamp_after_hour"    // 1小时后时间戳s格式:1587636854(s)
	TimeStampDay         = "timestamp_day"           // 1天前时间戳s格式:1587545094(s)
	TimeStampAfterDay    = "timestamp_after_day"     // 1天后时间戳s格式:1587719654(s)
	TimeStampMs          = "timestamp_ms"            // 当前时间戳ms格式:1587631494093(ms)
	TimeStampMsHour      = "timestamp_ms_hour"       // 1小时前时间戳ms格式:1587627894093(ms)
	TimeStampMsAfterHour = "timestamp_ms_after_hour" // 1小时后时间戳ms格式:1587636854150(ms)
	TimeStampMsDay       = "timestamp_ms_day"        // 1天前时间戳ms格式:1587545094093(ms)
	TimeStampMsAfterDay  = "timestamp_ms_after_day"  // 1天后时间戳ms格式:1587719654150(ms)
	TimeStampNs          = "timestamp_ns"            // 当前时间戳ns格式:1587631494093562000(ns)
	TimeStampNsHour      = "timestamp_ns_hour"       // 1小时前时间戳ns格式:1587627894093566000(ns)
	TimeStampNsAfterHour = "timestamp_ns_after_hour" // 1小时后时间戳ns格式:1587636854150072000(ns)
	TimeStampNsDay       = "timestamp_ns_day"        // 1天前前时间戳ns格式:1587545094093570000(ns)
	TimeStampNsAfterDay  = "timestamp_ns_after_day"  // 1天前后时间戳ns格式:1587719654150080000(ns)
	Date                 = "date"                    // 当前日期格式:2006-01-02
	DateDay              = "date_day"                // 1天前日期格式:2006-01-01
	DateTime             = "datetime"                // 当前带时间的格式:2006-01-02 15:04:05
	DateTimeHour         = "datetime_hour"           // 1小时前带时间的格式:2006-01-02 14:04:05
)

Variables

This section is empty.

Functions

func MockValue

func MockValue(mockType string) interface{}

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL