vehicle

package
v0.0.0-...-0dad8b8 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package vehicle is a generated GoMock package.

Index

Constants

This section is empty.

Variables

View Source
var Publish func()

Publish publishes vehicle updates at site level

Functions

This section is empty.

Types

type API

type API interface {
	// Instance returns the vehicle instance
	Instance() api.Vehicle

	// Name returns the vehicle name
	Name() string

	// GetMinSoc returns the min soc
	GetMinSoc() int
	// SetMinSoc sets the min soc
	SetMinSoc(soc int)
	// GetLimitSoc returns the limit soc
	GetLimitSoc() int
	// SetLimitSoc sets the limit soc
	SetLimitSoc(soc int)

	// GetPlanSoc returns the charge plan soc
	GetPlanSoc() (time.Time, int)
	// SetPlanSoc sets the charge plan time and soc
	SetPlanSoc(time.Time, int) error
}

func Adapter

func Adapter(log *util.Logger, dev config.Device[api.Vehicle]) API

Adapter creates a vehicle API adapter

func Settings

func Settings(log *util.Logger, v api.Vehicle) API

type MockAPI

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

MockAPI is a mock of API interface.

func NewMockAPI

func NewMockAPI(ctrl *gomock.Controller) *MockAPI

NewMockAPI creates a new mock instance.

func (*MockAPI) EXPECT

func (m *MockAPI) EXPECT() *MockAPIMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockAPI) GetLimitSoc

func (m *MockAPI) GetLimitSoc() int

GetLimitSoc mocks base method.

func (*MockAPI) GetMinSoc

func (m *MockAPI) GetMinSoc() int

GetMinSoc mocks base method.

func (*MockAPI) GetPlanSoc

func (m *MockAPI) GetPlanSoc() (time.Time, int)

GetPlanSoc mocks base method.

func (*MockAPI) Instance

func (m *MockAPI) Instance() api.Vehicle

Instance mocks base method.

func (*MockAPI) Name

func (m *MockAPI) Name() string

Name mocks base method.

func (*MockAPI) SetLimitSoc

func (m *MockAPI) SetLimitSoc(soc int)

SetLimitSoc mocks base method.

func (*MockAPI) SetMinSoc

func (m *MockAPI) SetMinSoc(soc int)

SetMinSoc mocks base method.

func (*MockAPI) SetPlanSoc

func (m *MockAPI) SetPlanSoc(arg0 time.Time, arg1 int) error

SetPlanSoc mocks base method.

type MockAPIMockRecorder

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

MockAPIMockRecorder is the mock recorder for MockAPI.

func (*MockAPIMockRecorder) GetLimitSoc

func (mr *MockAPIMockRecorder) GetLimitSoc() *gomock.Call

GetLimitSoc indicates an expected call of GetLimitSoc.

func (*MockAPIMockRecorder) GetMinSoc

func (mr *MockAPIMockRecorder) GetMinSoc() *gomock.Call

GetMinSoc indicates an expected call of GetMinSoc.

func (*MockAPIMockRecorder) GetPlanSoc

func (mr *MockAPIMockRecorder) GetPlanSoc() *gomock.Call

GetPlanSoc indicates an expected call of GetPlanSoc.

func (*MockAPIMockRecorder) Instance

func (mr *MockAPIMockRecorder) Instance() *gomock.Call

Instance indicates an expected call of Instance.

func (*MockAPIMockRecorder) Name

func (mr *MockAPIMockRecorder) Name() *gomock.Call

Name indicates an expected call of Name.

func (*MockAPIMockRecorder) SetLimitSoc

func (mr *MockAPIMockRecorder) SetLimitSoc(soc any) *gomock.Call

SetLimitSoc indicates an expected call of SetLimitSoc.

func (*MockAPIMockRecorder) SetMinSoc

func (mr *MockAPIMockRecorder) SetMinSoc(soc any) *gomock.Call

SetMinSoc indicates an expected call of SetMinSoc.

func (*MockAPIMockRecorder) SetPlanSoc

func (mr *MockAPIMockRecorder) SetPlanSoc(arg0, arg1 any) *gomock.Call

SetPlanSoc indicates an expected call of SetPlanSoc.

Jump to

Keyboard shortcuts

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