MCPcopy Create free account
hub / github.com/evcc-io/evcc / defaultMode

Method defaultMode

core/loadpoint.go:665–673  ·  view source on GitHub ↗

defaultMode executes the action

()

Source from the content-addressed store, hash-verified

663
664// defaultMode executes the action
665func (lp *Loadpoint) defaultMode() {
666 lp.RLock()
667 mode := lp.DefaultMode
668 lp.RUnlock()
669
670 if mode != "" && mode != lp.GetMode() {
671 lp.SetMode(mode)
672 }
673}
674
675// Prepare loadpoint configuration by adding missing helper elements
676func (lp *Loadpoint) Prepare(site site.API, uiChan chan<- util.Param, pushChan chan<- messenger.Event, lpChan chan<- *Loadpoint) {

Callers 1

Calls 4

RLockMethod · 0.95
RUnlockMethod · 0.95
GetModeMethod · 0.95
SetModeMethod · 0.95

Tested by

no test coverage detected