bundb

package
v0.12.2 Latest Latest
Warning

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

Go to latest
Published: May 12, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Checker

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

func NewChecker

func NewChecker(db *bun.DB) *Checker

func (*Checker) Check

func (c *Checker) Check(ctx context.Context) error

func (*Checker) Name

func (c *Checker) Name() string

type Ennoblement

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

func NewEnnoblement

func NewEnnoblement(db *bun.DB) *Ennoblement

func (*Ennoblement) Create

func (e *Ennoblement) Create(ctx context.Context, params ...domain.CreateEnnoblementParams) error

func (*Ennoblement) Delete added in v0.6.4

func (e *Ennoblement) Delete(ctx context.Context, serverKey string, createdAtLTE time.Time) error

func (*Ennoblement) List

func (*Ennoblement) ListCountWithRelations added in v0.5.5

func (e *Ennoblement) ListCountWithRelations(
	ctx context.Context,
	params domain.ListEnnoblementsParams,
) ([]domain.EnnoblementWithRelations, int64, error)

type Player

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

func NewPlayer

func NewPlayer(db *bun.DB) *Player

func (*Player) CreateOrUpdate

func (p *Player) CreateOrUpdate(ctx context.Context, params ...domain.CreatePlayerParams) error

func (*Player) Delete added in v0.4.0

func (p *Player) Delete(ctx context.Context, serverKey string, ids ...int64) error

func (*Player) List

func (p *Player) List(ctx context.Context, params domain.ListPlayersParams) ([]domain.Player, error)

func (*Player) ListCountWithRelations added in v0.5.5

func (p *Player) ListCountWithRelations(ctx context.Context, params domain.ListPlayersParams) ([]domain.PlayerWithRelations, int64, error)

type PlayerSnapshot added in v0.3.0

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

func NewPlayerSnapshot added in v0.3.0

func NewPlayerSnapshot(db *bun.DB) *PlayerSnapshot

func (*PlayerSnapshot) Create added in v0.3.0

func (*PlayerSnapshot) Delete added in v0.6.0

func (p *PlayerSnapshot) Delete(ctx context.Context, serverKey string, createdAtLTE time.Time) error

func (*PlayerSnapshot) List added in v0.6.0

func (*PlayerSnapshot) ListCountWithRelations added in v0.7.0

type Server

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

func NewServer

func NewServer(db *bun.DB) *Server

func (*Server) CreateOrUpdate

func (s *Server) CreateOrUpdate(ctx context.Context, params ...domain.CreateServerParams) ([]domain.Server, error)

func (*Server) List

func (s *Server) List(ctx context.Context, params domain.ListServersParams) ([]domain.Server, error)

func (*Server) ListCount added in v0.5.5

func (s *Server) ListCount(ctx context.Context, params domain.ListServersParams) ([]domain.Server, int64, error)

func (*Server) Update added in v0.4.0

func (s *Server) Update(ctx context.Context, key string, params domain.UpdateServerParams) (domain.Server, error)

type Tribe

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

func NewTribe

func NewTribe(db *bun.DB) *Tribe

func (*Tribe) CreateOrUpdate

func (t *Tribe) CreateOrUpdate(ctx context.Context, params ...domain.CreateTribeParams) error

func (*Tribe) Delete added in v0.4.0

func (t *Tribe) Delete(ctx context.Context, serverKey string, ids ...int64) error

func (*Tribe) List

func (t *Tribe) List(ctx context.Context, params domain.ListTribesParams) ([]domain.Tribe, error)

func (*Tribe) ListCount added in v0.5.5

func (t *Tribe) ListCount(ctx context.Context, params domain.ListTribesParams) ([]domain.Tribe, int64, error)

func (*Tribe) UpdateDominance

func (t *Tribe) UpdateDominance(ctx context.Context, serverKey string, numPlayerVillages int64) error

type TribeChange added in v0.4.0

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

func NewTribeChange added in v0.4.0

func NewTribeChange(db *bun.DB) *TribeChange

func (*TribeChange) Create added in v0.4.0

func (t *TribeChange) Create(ctx context.Context, params ...domain.CreateTribeChangeParams) error

func (*TribeChange) List added in v0.7.5

func (*TribeChange) ListCountWithRelations added in v0.7.5

func (t *TribeChange) ListCountWithRelations(
	ctx context.Context,
	params domain.ListTribeChangesParams,
) ([]domain.TribeChangeWithRelations, int64, error)

type TribeSnapshot added in v0.3.0

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

func NewTribeSnapshot added in v0.3.0

func NewTribeSnapshot(db *bun.DB) *TribeSnapshot

func (*TribeSnapshot) Create added in v0.3.0

func (*TribeSnapshot) Delete added in v0.6.0

func (t *TribeSnapshot) Delete(ctx context.Context, serverKey string, createdAtLTE time.Time) error

func (*TribeSnapshot) List added in v0.6.0

func (*TribeSnapshot) ListCount added in v0.10.0

type Version

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

func NewVersion

func NewVersion(db *bun.DB) *Version

func (*Version) GetByCode

func (v *Version) GetByCode(ctx context.Context, code string) (domain.Version, error)

func (*Version) List

func (v *Version) List(ctx context.Context) ([]domain.Version, error)

func (*Version) ListCount added in v0.5.5

func (v *Version) ListCount(ctx context.Context) ([]domain.Version, int64, error)

type Village

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

func NewVillage

func NewVillage(db *bun.DB) *Village

func (*Village) CreateOrUpdate

func (v *Village) CreateOrUpdate(ctx context.Context, params ...domain.CreateVillageParams) error

func (*Village) List

func (v *Village) List(ctx context.Context, params domain.ListVillagesParams) ([]domain.Village, error)

func (*Village) ListCountWithRelations added in v0.5.5

func (v *Village) ListCountWithRelations(ctx context.Context, params domain.ListVillagesParams) ([]domain.VillageWithRelations, int64, error)

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

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