Documentation ¶
Index ¶
- Variables
- func CheckCode(idBody string) (string, bool)
- func Validate(id string) bool
- type ChinaID
- func (c *ChinaID) Addr() string
- func (c *ChinaID) Birth() string
- func (c *ChinaID) Body() string
- func (c *ChinaID) Check() string
- func (c *ChinaID) Format(f fmt.State, r rune)
- func (c *ChinaID) IsFemale() bool
- func (c *ChinaID) IsMale() bool
- func (c *ChinaID) MarshalJSON() ([]byte, error)
- func (c *ChinaID) Seq() string
- func (c *ChinaID) Sex() int
- func (c *ChinaID) SexText() string
- func (c *ChinaID) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidChinaID = errors.New("invalid China ID")
ErrInvalidChinaID error
Functions ¶
Types ¶
type ChinaID ¶
type ChinaID struct {
// contains filtered or unexported fields
}
ChinaID Chinese identity card number
func (*ChinaID) MarshalJSON ¶
MarshalJSON implements json.Marshaler
Click to show internal directories.
Click to hide internal directories.