structs

package
v1.6.3 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const DateFormat = "2006-01-02T15:04:05Z"

Variables

View Source
var (
	CRC16_ARC         = ZeroCRC16Params{0x8005, 0x0000, true, true, 0x0000, "CRC-16/ARC"}
	CRC16_AUG_CCITT   = ZeroCRC16Params{0x1021, 0x1D0F, false, false, 0x0000, "CRC-16/AUG-CCITT"}
	CRC16_BUYPASS     = ZeroCRC16Params{0x8005, 0x0000, false, false, 0x0000, "CRC-16/BUYPASS"}
	CRC16_CCITT_FALSE = ZeroCRC16Params{0x1021, 0xFFFF, false, false, 0x0000, "CRC-16/CCITT-FALSE"}
	CRC16_CDMA2000    = ZeroCRC16Params{0xC867, 0xFFFF, false, false, 0x0000, "CRC-16/CDMA2000"}
	CRC16_DDS_110     = ZeroCRC16Params{0x8005, 0x800D, false, false, 0x0000, "CRC-16/DDS-110"}
	CRC16_DECT_R      = ZeroCRC16Params{0x0589, 0x0000, false, false, 0x0001, "CRC-16/DECT-R"}
	CRC16_DECT_X      = ZeroCRC16Params{0x0589, 0x0000, false, false, 0x0000, "CRC-16/DECT-X"}
	CRC16_DNP         = ZeroCRC16Params{0x3D65, 0x0000, true, true, 0xFFFF, "CRC-16/DNP"}
	CRC16_EN_13757    = ZeroCRC16Params{0x3D65, 0x0000, false, false, 0xFFFF, "CRC-16/EN-13757"}
	CRC16_GENIBUS     = ZeroCRC16Params{0x1021, 0xFFFF, false, false, 0xFFFF, "CRC-16/GENIBUS"}
	CRC16_MAXIM       = ZeroCRC16Params{0x8005, 0x0000, true, true, 0xFFFF, "CRC-16/MAXIM"}
	CRC16_MCRF4XX     = ZeroCRC16Params{0x1021, 0xFFFF, true, true, 0x0000, "CRC-16/MCRF4XX"}
	CRC16_RIELLO      = ZeroCRC16Params{0x1021, 0xB2AA, true, true, 0x0000, "CRC-16/RIELLO"}
	CRC16_T10_DIF     = ZeroCRC16Params{0x8BB7, 0x0000, false, false, 0x0000, "CRC-16/T10-DIF"}
	CRC16_TELEDISK    = ZeroCRC16Params{0xA097, 0x0000, false, false, 0x0000, "CRC-16/TELEDISK"}
	CRC16_TMS37157    = ZeroCRC16Params{0x1021, 0x89EC, true, true, 0x0000, "CRC-16/TMS37157"}
	CRC16_USB         = ZeroCRC16Params{0x8005, 0xFFFF, true, true, 0xFFFF, "CRC-16/USB"}
	CRC16_CRC_A       = ZeroCRC16Params{0x1021, 0xC6C6, true, true, 0x0000, "CRC-16/CRC-A"}
	CRC16_KERMIT      = ZeroCRC16Params{0x1021, 0x0000, true, true, 0x0000, "CRC-16/KERMIT"}
	CRC16_MODBUS      = ZeroCRC16Params{0x8005, 0xFFFF, true, true, 0x0000, "CRC-16/MODBUS"}
	CRC16_X_25        = ZeroCRC16Params{0x1021, 0xFFFF, true, true, 0xFFFF, "CRC-16/X-25"}
	CRC16_XMODEM      = ZeroCRC16Params{0x1021, 0x0000, false, false, 0x0000, "CRC-16/XMODEM"}
)

Functions

func BirthdayWithIDCard

func BirthdayWithIDCard(idCard string) (*time.Time, error)

func CheckISO70641983MOD112

func CheckISO70641983MOD112(idCard string) bool

func SexWithIDCard

func SexWithIDCard(idCard string) (int, error)

Types

type Date

type Date time.Time

func (Date) MarshalJSON

func (t Date) MarshalJSON() ([]byte, error)

func (Date) Time

func (t Date) Time() time.Time

func (*Date) UnmarshalJSON

func (t *Date) UnmarshalJSON(data []byte) error

type ZeroCRC16Params added in v1.5.0

type ZeroCRC16Params struct {
	Poly   uint16
	Init   uint16
	RefIn  bool
	RefOut bool
	XorOut uint16
	Name   string
}

type ZeroCRC16Table added in v1.5.0

type ZeroCRC16Table struct {
	// contains filtered or unexported fields
}

func NewCRC16Table added in v1.5.0

func NewCRC16Table(params ZeroCRC16Params) *ZeroCRC16Table

func (*ZeroCRC16Table) Complete added in v1.5.0

func (table *ZeroCRC16Table) Complete(data []byte) uint16

type ZeroCoreStructs

type ZeroCoreStructs struct {
	ID         string                 `json:"id,omitempty"`
	CreateTime Date                   `json:"createTime,omitempty"`
	UpdateTime Date                   `json:"updateTime,omitempty"`
	Features   map[string]interface{} `json:"features,omitempty"`
}

func (*ZeroCoreStructs) GetJSONFeature

func (e *ZeroCoreStructs) GetJSONFeature() string

func (*ZeroCoreStructs) InitDefault

func (e *ZeroCoreStructs) InitDefault() error

func (*ZeroCoreStructs) LoadRowData

func (e *ZeroCoreStructs) LoadRowData(rowmap map[string]interface{})

func (*ZeroCoreStructs) SetJSONFeature

func (e *ZeroCoreStructs) SetJSONFeature(jsonString string)

func (*ZeroCoreStructs) String

func (e *ZeroCoreStructs) String() string

func (*ZeroCoreStructs) UInt8ToString

func (e *ZeroCoreStructs) UInt8ToString(bs []uint8) string

type ZeroMeta added in v1.4.2

type ZeroMeta struct {
	// contains filtered or unexported fields
}

func (*ZeroMeta) This added in v1.4.2

func (meta *ZeroMeta) This() interface{}

func (*ZeroMeta) ThisDef added in v1.4.4

func (meta *ZeroMeta) ThisDef(_self interface{})

type ZeroMetaDef added in v1.4.2

type ZeroMetaDef interface {
	This() interface{}
	ThisDef(interface{})
}

type ZeroMetaPtr added in v1.4.2

type ZeroMetaPtr struct {
	// contains filtered or unexported fields
}

type ZeroRequest

type ZeroRequest struct {
	Querys  []interface{}          `json:"querys,omitempty"`
	Expands map[string]interface{} `json:"expands,omitempty"`
}

type ZeroResponse

type ZeroResponse struct {
	Code    int                    `json:"code,omitempty"`
	Message string                 `json:"message,omitempty"`
	Datas   []interface{}          `json:"datas,omitempty"`
	Expands map[string]interface{} `json:"expands,omitempty"`
}

Jump to

Keyboard shortcuts

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