calendardates

package
v0.0.0-...-651d898 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2022 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CalendarDate

type CalendarDate struct {
	ID            int32             `csv:"id"`
	ServiceID     string            `csv:"service_id"`
	Date          time.Time         `csv:"date"`
	ExceptionType NullExceptionType `csv:"exception_type,omitempty"`
}

type CreateCalendarDateParams

type CreateCalendarDateParams struct {
	ServiceID     string            `db:"service_id"`
	Date          time.Time         `db:"date"`
	ExceptionType NullExceptionType `db:"exception_type"`
}

type DBTX

type DBTX interface {
	ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
	PrepareContext(context.Context, string) (*sql.Stmt, error)
	QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
	QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}

type ExceptionType

type ExceptionType string
const (
	ExceptionTypeServiceAdded   ExceptionType = "ServiceAdded"
	ExceptionTypeServiceRemoved ExceptionType = "ServiceRemoved"
)

func (*ExceptionType) Scan

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

type NullExceptionType

type NullExceptionType struct {
	ExceptionType ExceptionType
	Valid         bool // Valid is true if ExceptionType is not NULL
}

func (*NullExceptionType) Scan

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

Scan implements the Scanner interface.

func (NullExceptionType) Value

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

Value implements the driver Valuer interface.

type Queries

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

func New

func New(db DBTX) *Queries

func Prepare

func Prepare(ctx context.Context, db DBTX) (*Queries, error)

func (*Queries) Close

func (q *Queries) Close() error

func (*Queries) CreateCalendarDate

func (q *Queries) CreateCalendarDate(ctx context.Context, arg CreateCalendarDateParams) error

func (*Queries) GetCalendarDateByID

func (q *Queries) GetCalendarDateByID(ctx context.Context, id int32) (CalendarDate, error)

func (*Queries) WithTx

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

Jump to

Keyboard shortcuts

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