clock

package
v0.0.67 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2021 License: GPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Clock

type Clock struct {
	sync.Mutex
	// contains filtered or unexported fields
}

Clock implements board.Board

func New

func New(config *Config, logger *zap.Logger) (*Clock, error)

New returns a new Clock board

func (*Clock) Cleanup

func (c *Clock) Cleanup()

Cleanup ...

func (*Clock) Disable added in v0.0.8

func (c *Clock) Disable()

Disable ...

func (*Clock) Enable added in v0.0.8

func (c *Clock) Enable()

Enable ...

func (*Clock) Enabled

func (c *Clock) Enabled() bool

Enabled ...

func (*Clock) GetHTTPHandlers

func (c *Clock) GetHTTPHandlers() ([]*board.HTTPHandler, error)

GetHTTPHandlers ...

func (*Clock) GetRPCHandler added in v0.0.63

func (c *Clock) GetRPCHandler() (string, http.Handler)

GetRPCHandler ...

func (*Clock) HasPriority

func (c *Clock) HasPriority() bool

HasPriority ...

func (*Clock) Name

func (c *Clock) Name() string

Name ...

func (*Clock) Render

func (c *Clock) Render(ctx context.Context, canvas board.Canvas) error

Render ...

func (*Clock) ScrollMode added in v0.0.29

func (c *Clock) ScrollMode() bool

ScrollMode ...

type Config

type Config struct {
	Enabled    *atomic.Bool `json:"enabled"`
	BoardDelay string       `json:"boardDelay"`
	OnTimes    []string     `json:"onTimes"`
	OffTimes   []string     `json:"offTimes"`
	// contains filtered or unexported fields
}

Config is a Clock configuration

func (*Config) SetDefaults

func (c *Config) SetDefaults()

SetDefaults ...

type Server added in v0.0.63

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

Server ...

func (*Server) GetStatus added in v0.0.63

func (s *Server) GetStatus(ctx context.Context, req *emptypb.Empty) (*pb.StatusResp, error)

GetStatus ...

func (*Server) SetStatus added in v0.0.63

func (s *Server) SetStatus(ctx context.Context, req *pb.SetStatusReq) (*emptypb.Empty, error)

SetStatus ...

Jump to

Keyboard shortcuts

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