Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotSupported = errors.New("preventing system sleep is not supported on this platform") ErrNotStarted = errors.New("caffeinate is not started") ErrAlreadyStarted = errors.New("caffeinate is already started") ErrNotRunning = errors.New("caffeinate is no longer running") ErrPermissionDenied = errors.New("permission denied, you must use sudo to perform this operation") )
Functions ¶
This section is empty.
Types ¶
type Caffeinate ¶
type Caffeinate struct {
// contains filtered or unexported fields
}
func New ¶
func New() *Caffeinate
func (*Caffeinate) IsRunning ¶
func (c *Caffeinate) IsRunning() bool
func (*Caffeinate) Start ¶
func (c *Caffeinate) Start() error
func (*Caffeinate) Stop ¶
func (c *Caffeinate) Stop() error
Click to show internal directories.
Click to hide internal directories.