Documentation ¶
Index ¶
- Constants
- type RedisConfigStore
- func (s *RedisConfigStore) FEHash(ctx context.Context) (string, error)
- func (s *RedisConfigStore) GamesEnabled(ctx context.Context) (bool, error)
- func (s *RedisConfigStore) GetAnnouncements(ctx context.Context) ([]*pb.Announcement, error)
- func (s *RedisConfigStore) SetAnnouncement(ctx context.Context, linkSearchString string, announcement *pb.Announcement) error
- func (s *RedisConfigStore) SetAnnouncements(ctx context.Context, announcements []*pb.Announcement) error
- func (s *RedisConfigStore) SetFEHash(ctx context.Context, hash string) error
- func (s *RedisConfigStore) SetGamesEnabled(ctx context.Context, enabled bool) error
Constants ¶
View Source
const ( GamesDisabledKey = "config:games-disabled" FEHashKey = "config:fe-hash" // Front-page announcements. Some of these could later be dynamically // updated from a blog or something. AnnouncementsKey = "config:static-announcements" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisConfigStore ¶
type RedisConfigStore struct {
// contains filtered or unexported fields
}
func NewRedisConfigStore ¶
func NewRedisConfigStore(r *redis.Pool) *RedisConfigStore
func (*RedisConfigStore) FEHash ¶
func (s *RedisConfigStore) FEHash(ctx context.Context) (string, error)
func (*RedisConfigStore) GamesEnabled ¶
func (s *RedisConfigStore) GamesEnabled(ctx context.Context) (bool, error)
func (*RedisConfigStore) GetAnnouncements ¶
func (s *RedisConfigStore) GetAnnouncements(ctx context.Context) ([]*pb.Announcement, error)
func (*RedisConfigStore) SetAnnouncement ¶
func (s *RedisConfigStore) SetAnnouncement(ctx context.Context, linkSearchString string, announcement *pb.Announcement) error
func (*RedisConfigStore) SetAnnouncements ¶
func (s *RedisConfigStore) SetAnnouncements(ctx context.Context, announcements []*pb.Announcement) error
func (*RedisConfigStore) SetFEHash ¶
func (s *RedisConfigStore) SetFEHash(ctx context.Context, hash string) error
func (*RedisConfigStore) SetGamesEnabled ¶
func (s *RedisConfigStore) SetGamesEnabled(ctx context.Context, enabled bool) error
Click to show internal directories.
Click to hide internal directories.