Documentation
¶
Index ¶
- type CreateBulkUserParams
- type CreateUserParams
- type DBTX
- type ListActiveParams
- type ListUserFilterByAgeNameParams
- type ListUserFilterByAgeNameRow
- type Queries
- func (q *Queries) CreateBulkUser(ctx context.Context, arg CreateBulkUserParams) (int32, error)
- func (q *Queries) CreateUser(ctx context.Context, arg CreateUserParams) (int32, error)
- func (q *Queries) DB() DBTX
- func (q *Queries) DeleteAllUser(ctx context.Context) error
- func (q *Queries) DeleteUser(ctx context.Context, id int32) error
- func (q *Queries) GetUserByEmail(ctx context.Context, email string) (User, error)
- func (q *Queries) GetUserByID(ctx context.Context, id int32) (User, error)
- func (q *Queries) ListActive(ctx context.Context, arg ListActiveParams) ([]User, error)
- func (q *Queries) ListAllUser(ctx context.Context) ([]User, error)
- func (q *Queries) ListUserFilterByAgeName(ctx context.Context, arg ListUserFilterByAgeNameParams) ([]ListUserFilterByAgeNameRow, error)
- func (q *Queries) UpdateUser(ctx context.Context, arg UpdateUserParams) (User, error)
- func (q *Queries) WithTx(tx *sql.Tx) *Queries
- type UpdateUserParams
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateBulkUserParams ¶
type CreateBulkUserParams struct {
Email string `json:"email"`
Name string `json:"name"`
Age sql.NullInt32 `json:"age"`
Password string `json:"password"`
ApiKey []byte `json:"api_key"`
IsActive bool `json:"is_active"`
LoginCount int64 `json:"login_count"`
Rating float64 `json:"rating"`
Preferences json.RawMessage `json:"preferences"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type CreateUserParams ¶
type CreateUserParams struct {
Email string `json:"email"`
Name string `json:"name"`
Age sql.NullInt32 `json:"age"`
Password string `json:"password"`
ApiKey []byte `json:"api_key"`
IsActive bool `json:"is_active"`
LoginCount int64 `json:"login_count"`
Rating float64 `json:"rating"`
Preferences json.RawMessage `json:"preferences"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type ListActiveParams ¶ added in v0.0.4
type ListUserFilterByAgeNameRow ¶ added in v0.0.5
type ListUserFilterByAgeNameRow struct {
ID int32 `json:"id"`
Email string `json:"email"`
Name string `json:"name"`
Age sql.NullInt32 `json:"age"`
Password string `json:"password"`
ApiKey []byte `json:"api_key"`
IsActive bool `json:"is_active"`
LoginCount int64 `json:"login_count"`
Rating float64 `json:"rating"`
Preferences json.RawMessage `json:"preferences"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
TotalSize int64 `json:"total_size"`
}
type Queries ¶
type Queries struct {
// contains filtered or unexported fields
}
func (*Queries) CreateBulkUser ¶
re-importing the same users overwrites the row that shares the email
func (*Queries) CreateUser ¶
Code generated by entlite. DO NOT EDIT. SQLC compatible query definitions User CRUD operations
func (*Queries) GetUserByEmail ¶
Look up a user by email address
func (*Queries) GetUserByID ¶
func (*Queries) ListActive ¶
func (*Queries) ListUserFilterByAgeName ¶
func (q *Queries) ListUserFilterByAgeName(ctx context.Context, arg ListUserFilterByAgeNameParams) ([]ListUserFilterByAgeNameRow, error)
func (*Queries) UpdateUser ¶
type UpdateUserParams ¶
type UpdateUserParams struct {
Email string `json:"email"`
Name string `json:"name"`
Age sql.NullInt32 `json:"age"`
Password sql.NullString `json:"password"`
IsActive sql.NullBool `json:"is_active"`
LoginCount sql.NullInt64 `json:"login_count"`
Rating sql.NullFloat64 `json:"rating"`
Preferences pqtype.NullRawMessage `json:"preferences"`
UpdatedAt time.Time `json:"updated_at"`
ID int32 `json:"id"`
}
type User ¶
type User struct {
ID int32 `json:"id"`
Email string `json:"email"`
Name string `json:"name"`
Age sql.NullInt32 `json:"age"`
Password string `json:"password"`
ApiKey []byte `json:"api_key"`
IsActive bool `json:"is_active"`
LoginCount int64 `json:"login_count"`
Rating float64 `json:"rating"`
Preferences json.RawMessage `json:"preferences"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
Click to show internal directories.
Click to hide internal directories.