add state filtering to effect enforcer.
This commit is contained in:
+11
-1
@@ -30,7 +30,17 @@ func (c SetState) VerboseKey() string {
|
||||
type SetStateBatch map[string]device.State
|
||||
|
||||
func (c SetStateBatch) CommandDescription() string {
|
||||
return fmt.Sprintf("SetStateBatch(%d devices)", len(c))
|
||||
b := strings.Builder{}
|
||||
b.WriteByte('\n')
|
||||
for key, value := range c {
|
||||
b.WriteString(" ")
|
||||
b.WriteString(key)
|
||||
b.WriteString(": ")
|
||||
b.WriteString(value.String())
|
||||
b.WriteRune('\n')
|
||||
}
|
||||
|
||||
return fmt.Sprintf("SetStateBatch(%s)", b.String())
|
||||
}
|
||||
|
||||
func (c SetStateBatch) VerboseKey() string {
|
||||
|
||||
Reference in New Issue
Block a user