Documentation
¶
Index ¶
- Constants
- Variables
- type Config
- type Generator
- type ID
- func (id ID) Encode() string
- func (ID) GormDBDataType(db *gorm.DB, field *schema.Field) string
- func (id ID) GormValue(ctx context.Context, db *gorm.DB) clause.Expr
- func (id ID) Int64() int64
- func (id ID) IsValid() bool
- func (id ID) IsZero() bool
- func (id ID) MarshalBinary() ([]byte, error)
- func (id ID) MarshalJSON() ([]byte, error)
- func (id *ID) Scan(value any) error
- func (id ID) String() string
- func (id *ID) UnmarshalBinary(data []byte) error
- func (id *ID) UnmarshalJSON(data []byte) error
- func (id ID) Value() (driver.Value, error)
Constants ¶
View Source
const ( Alphabet = "abcdefghijklmnopqrstuvwxyz0123456789" Size = 6 MaxValue = 36 * 36 * 36 * 36 * 36 * 36 )
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Generator ¶
type Generator struct {
// contains filtered or unexported fields
}
func (*Generator) MustGenerate ¶
type ID ¶
type ID int64
func MustGenerate ¶
func MustGenerate() ID
func ParseString ¶
func (ID) MarshalBinary ¶
func (ID) MarshalJSON ¶
func (*ID) UnmarshalBinary ¶
func (*ID) UnmarshalJSON ¶
Click to show internal directories.
Click to hide internal directories.