models

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2022 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AudioTrack

type AudioTrack struct {
	Track    string         `json:"track"`
	UserData AudioTrackData `json:"user_data"`
}

type AudioTrackData

type AudioTrackData struct {
	Requester snowflake.Snowflake `json:"requester"`
}

type GuildSettings

type GuildSettings struct {
	ID snowflake.Snowflake `bun:"id,pk,notnull"`
}

type LikedSong

type LikedSong struct {
	UserID    snowflake.Snowflake `bun:"user_id,pk"`
	Query     string              `bun:"query,notnull"`
	Title     string              `bun:"title,pk"`
	CreatedAt time.Time           `bun:"created_at,nullzero,notnull,default:current_timestamp"`
}

type MusicPlayer

type MusicPlayer struct {
	GuildID              snowflake.Snowflake   `bun:"guild_id,pk,notnull"`
	State                []byte                `bun:"state,notnull"`
	PlayingTrackUserData *AudioTrackData       `bun:"playing_track_user_data"`
	Type                 int                   `bun:"type,notnull"`
	Queue                []AudioTrack          `bun:"queue,notnull"`
	LoopingType          int                   `bun:"looping_type,notnull"`
	History              []AudioTrack          `bun:"history,notnull"`
	SkipVotes            []snowflake.Snowflake `bun:"skip_votes,notnull"`
}

type PlayHistory

type PlayHistory struct {
	UserID     snowflake.Snowflake `bun:"user_id,pk"`
	Query      string              `bun:"query,notnull"`
	Title      string              `bun:"title,pk"`
	LastUsedAt time.Time           `bun:"last_used_at,nullzero,notnull,default:current_timestamp"`
}

type Tag

type Tag struct {
	ID        int                 `bun:"id,autoincrement,pk,notnull"`
	GuildID   snowflake.Snowflake `bun:"guild_id,notnull,unique:name-guild"`
	OwnerID   snowflake.Snowflake `bun:"owner_id,notnull"`
	Name      string              `bun:"name,notnull,unique:name-guild"`
	Content   string              `bun:"content,notnull"`
	Uses      int                 `bun:"uses,default:0"`
	CreatedAt time.Time           `bun:"created_at,nullzero,notnull,default:current_timestamp"`
}

Jump to

Keyboard shortcuts

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