35 lines
667 B
Go
35 lines
667 B
Go
package charger
|
|
|
|
// Code generated by github.com/evcc-io/evcc/cmd/tools/decorate.go. DO NOT EDIT.
|
|
|
|
import (
|
|
"github.com/evcc-io/evcc/api"
|
|
)
|
|
|
|
func decorateOpenWB20(base *OpenWB20, identifier func() (string, error)) api.Charger {
|
|
switch {
|
|
case identifier == nil:
|
|
return base
|
|
|
|
case identifier != nil:
|
|
return &struct {
|
|
*OpenWB20
|
|
api.Identifier
|
|
}{
|
|
OpenWB20: base,
|
|
Identifier: &decorateOpenWB20IdentifierImpl{
|
|
identifier: identifier,
|
|
},
|
|
}
|
|
}
|
|
|
|
return nil
|
|
}
|
|
|
|
type decorateOpenWB20IdentifierImpl struct {
|
|
identifier func() (string, error)
|
|
}
|
|
|
|
func (impl *decorateOpenWB20IdentifierImpl) Identify() (string, error) {
|
|
return impl.identifier()
|
|
}
|