sqlc

package
v0.0.0-...-eccf6c2 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DBTX

type DBTX interface {
	Exec(context.Context, string, ...interface{}) (pgconn.CommandTag, error)
	Query(context.Context, string, ...interface{}) (pgx.Rows, error)
	QueryRow(context.Context, string, ...interface{}) pgx.Row
}

type Friend

type Friend struct {
	ID           pgtype.UUID
	PersonaID1   pgtype.UUID
	PersonaID2   pgtype.UUID
	Status       FriendStatus
	CreatedAt    pgtype.Timestamptz
	UpdatedAt    pgtype.Timestamptz
	NamePersona1 string
	NamePersona2 string
}

type FriendStatus

type FriendStatus string
const (
	FriendStatusPending  FriendStatus = "pending"
	FriendStatusAccepted FriendStatus = "accepted"
	FriendStatusBlocked  FriendStatus = "blocked"
)

func (*FriendStatus) Scan

func (e *FriendStatus) Scan(src interface{}) error

type NullFriendStatus

type NullFriendStatus struct {
	FriendStatus FriendStatus
	Valid        bool // Valid is true if FriendStatus is not NULL
}

func (*NullFriendStatus) Scan

func (ns *NullFriendStatus) Scan(value interface{}) error

Scan implements the Scanner interface.

func (NullFriendStatus) Value

func (ns NullFriendStatus) Value() (driver.Value, error)

Value implements the driver Valuer interface.

type Persona

type Persona struct {
	ID        pgtype.UUID
	CreatedAt pgtype.Timestamptz
}

type Queries

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

func New

func New(db DBTX) *Queries

func (*Queries) CreatePersona

func (q *Queries) CreatePersona(ctx context.Context, id pgtype.UUID) (pgtype.UUID, error)

func (*Queries) WithTx

func (q *Queries) WithTx(tx pgx.Tx) *Queries

Jump to

Keyboard shortcuts

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