Documentation ¶
Index ¶
- Variables
- type DB
- func (db *DB) AddSeason(ctx context.Context, newSeason SeasonInput) (*Season, error)
- func (db *DB) GetAllSeasons(ctx context.Context) ([]Season, error)
- func (db *DB) GetSeason(ctx context.Context, uuid uuid.UUID) (*Season, error)
- func (db *DB) GetSeasonByName(ctx context.Context, name string) (*Season, error)
- func (db *DB) UpdateSeason(ctx context.Context, id uuid.UUID, season SeasonInput) (*Season, error)
- type DynamoDBClient
- type Game
- type Season
- type SeasonInput
- type Team
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrItemNotFound = errors.New("item not found") ErrItemAlreadyExists = errors.New("item already exists") )
Functions ¶
This section is empty.
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
func NewDB ¶
func NewDB(tableName string, entityTypeIndexName string, dynamoClient DynamoDBClient) *DB
func (*DB) GetSeasonByName ¶
func (*DB) UpdateSeason ¶
type DynamoDBClient ¶
type DynamoDBClient interface { GetItem(context.Context, *dynamodb.GetItemInput, ...func(*dynamodb.Options)) (*dynamodb.GetItemOutput, error) PutItem(context.Context, *dynamodb.PutItemInput, ...func(*dynamodb.Options)) (*dynamodb.PutItemOutput, error) Query(context.Context, *dynamodb.QueryInput, ...func(*dynamodb.Options)) (*dynamodb.QueryOutput, error) UpdateItem(context.Context, *dynamodb.UpdateItemInput, ...func(*dynamodb.Options)) (*dynamodb.UpdateItemOutput, error) }
type SeasonInput ¶
Click to show internal directories.
Click to hide internal directories.