Documentation ¶
Overview ¶
Package storage provides database-related implementations.
Index ¶
Constants ¶
View Source
const GreetingsTable = "greetings"
GreetingsTable is the name of the table.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GreetingRow ¶
type GreetingRow struct { ID int `db:"id,omitempty"` Message string `db:"message"` CreatedAt time.Time `db:"created_at"` }
GreetingRow describes database mapping.
type GreetingSaver ¶
GreetingSaver saves greetings to database.
func (*GreetingSaver) ClearGreetings ¶
func (gs *GreetingSaver) ClearGreetings(ctx context.Context) (int, error)
ClearGreetings removes all entries.
func (*GreetingSaver) GreetingClearer ¶
func (gs *GreetingSaver) GreetingClearer() greeting.Clearer
GreetingClearer implements service provider.
func (*GreetingSaver) GreetingMaker ¶
func (gs *GreetingSaver) GreetingMaker() greeting.Maker
GreetingMaker implements service provider.
Click to show internal directories.
Click to hide internal directories.