Documentation
¶
Overview ¶
Package store is a generated GoMock package.
Index ¶
- type KvStore
- type MockKvStore
- type MockKvStoreDeleteCall
- type MockKvStoreGetCall
- type MockKvStoreListCall
- type MockKvStoreMockRecorder
- type MockKvStorePutCall
- type MockObjectStore
- type MockObjectStoreGetCall
- type MockObjectStoreMockRecorder
- type MockObjectStorePutCall
- type MockPostStore
- func (m *MockPostStore) Delete(ID meta.PostID) error
- func (m *MockPostStore) EXPECT() *MockPostStoreMockRecorder
- func (m *MockPostStore) Get(ID meta.PostID) (*meta.Post, error)
- func (m *MockPostStore) List(offset, limit int) ([]*meta.Post, error)
- func (m *MockPostStore) Put(ID meta.PostID, post *meta.Post) error
- type MockPostStoreDeleteCall
- type MockPostStoreGetCall
- type MockPostStoreListCall
- type MockPostStoreMockRecorder
- func (mr *MockPostStoreMockRecorder) Delete(ID any) *MockPostStoreDeleteCall
- func (mr *MockPostStoreMockRecorder) Get(ID any) *MockPostStoreGetCall
- func (mr *MockPostStoreMockRecorder) List(offset, limit any) *MockPostStoreListCall
- func (mr *MockPostStoreMockRecorder) Put(ID, post any) *MockPostStorePutCall
- type MockPostStorePutCall
- type MockStringer
- type MockStringerLoadCall
- type MockStringerMockRecorder
- type MockStringerStringCall
- type MockUserStore
- func (m *MockUserStore) Delete(ID meta.UserID) error
- func (m *MockUserStore) EXPECT() *MockUserStoreMockRecorder
- func (m *MockUserStore) Get(ID meta.UserID) (*meta.User, error)
- func (m *MockUserStore) List(offset, limit int) ([]*meta.User, error)
- func (m *MockUserStore) Put(ID meta.UserID, user *meta.User) error
- type MockUserStoreDeleteCall
- type MockUserStoreGetCall
- type MockUserStoreListCall
- type MockUserStoreMockRecorder
- func (mr *MockUserStoreMockRecorder) Delete(ID any) *MockUserStoreDeleteCall
- func (mr *MockUserStoreMockRecorder) Get(ID any) *MockUserStoreGetCall
- func (mr *MockUserStoreMockRecorder) List(offset, limit any) *MockUserStoreListCall
- func (mr *MockUserStoreMockRecorder) Put(ID, user any) *MockUserStorePutCall
- type MockUserStorePutCall
- type ObjectStore
- type PostStore
- type Stringer
- type UserStore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockKvStore ¶
type MockKvStore struct {
// contains filtered or unexported fields
}
MockKvStore is a mock of KvStore interface.
func NewMockKvStore ¶
func NewMockKvStore(ctrl *gomock.Controller) *MockKvStore
NewMockKvStore creates a new mock instance.
func (*MockKvStore) Delete ¶
func (m *MockKvStore) Delete(key string) error
Delete mocks base method.
func (*MockKvStore) EXPECT ¶
func (m *MockKvStore) EXPECT() *MockKvStoreMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockKvStore) Get ¶
func (m *MockKvStore) Get(key string) (string, error)
Get mocks base method.
type MockKvStoreDeleteCall ¶
MockKvStoreDeleteCall wrap *gomock.Call
func (*MockKvStoreDeleteCall) Do ¶
func (c *MockKvStoreDeleteCall) Do(f func(string) error) *MockKvStoreDeleteCall
Do rewrite *gomock.Call.Do
func (*MockKvStoreDeleteCall) DoAndReturn ¶
func (c *MockKvStoreDeleteCall) DoAndReturn(f func(string) error) *MockKvStoreDeleteCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockKvStoreDeleteCall) Return ¶
func (c *MockKvStoreDeleteCall) Return(arg0 error) *MockKvStoreDeleteCall
Return rewrite *gomock.Call.Return
type MockKvStoreGetCall ¶
MockKvStoreGetCall wrap *gomock.Call
func (*MockKvStoreGetCall) Do ¶
func (c *MockKvStoreGetCall) Do(f func(string) (string, error)) *MockKvStoreGetCall
Do rewrite *gomock.Call.Do
func (*MockKvStoreGetCall) DoAndReturn ¶
func (c *MockKvStoreGetCall) DoAndReturn(f func(string) (string, error)) *MockKvStoreGetCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockKvStoreGetCall) Return ¶
func (c *MockKvStoreGetCall) Return(arg0 string, arg1 error) *MockKvStoreGetCall
Return rewrite *gomock.Call.Return
type MockKvStoreListCall ¶
MockKvStoreListCall wrap *gomock.Call
func (*MockKvStoreListCall) Do ¶
func (c *MockKvStoreListCall) Do(f func(int, int) ([]string, error)) *MockKvStoreListCall
Do rewrite *gomock.Call.Do
func (*MockKvStoreListCall) DoAndReturn ¶
func (c *MockKvStoreListCall) DoAndReturn(f func(int, int) ([]string, error)) *MockKvStoreListCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockKvStoreListCall) Return ¶
func (c *MockKvStoreListCall) Return(arg0 []string, arg1 error) *MockKvStoreListCall
Return rewrite *gomock.Call.Return
type MockKvStoreMockRecorder ¶
type MockKvStoreMockRecorder struct {
// contains filtered or unexported fields
}
MockKvStoreMockRecorder is the mock recorder for MockKvStore.
func (*MockKvStoreMockRecorder) Delete ¶
func (mr *MockKvStoreMockRecorder) Delete(key any) *MockKvStoreDeleteCall
Delete indicates an expected call of Delete.
func (*MockKvStoreMockRecorder) Get ¶
func (mr *MockKvStoreMockRecorder) Get(key any) *MockKvStoreGetCall
Get indicates an expected call of Get.
func (*MockKvStoreMockRecorder) List ¶
func (mr *MockKvStoreMockRecorder) List(offset, limit any) *MockKvStoreListCall
List indicates an expected call of List.
func (*MockKvStoreMockRecorder) Put ¶
func (mr *MockKvStoreMockRecorder) Put(key, value any) *MockKvStorePutCall
Put indicates an expected call of Put.
type MockKvStorePutCall ¶
MockKvStorePutCall wrap *gomock.Call
func (*MockKvStorePutCall) Do ¶
func (c *MockKvStorePutCall) Do(f func(string, Stringer) error) *MockKvStorePutCall
Do rewrite *gomock.Call.Do
func (*MockKvStorePutCall) DoAndReturn ¶
func (c *MockKvStorePutCall) DoAndReturn(f func(string, Stringer) error) *MockKvStorePutCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockKvStorePutCall) Return ¶
func (c *MockKvStorePutCall) Return(arg0 error) *MockKvStorePutCall
Return rewrite *gomock.Call.Return
type MockObjectStore ¶
type MockObjectStore struct {
// contains filtered or unexported fields
}
MockObjectStore is a mock of ObjectStore interface.
func NewMockObjectStore ¶
func NewMockObjectStore(ctrl *gomock.Controller) *MockObjectStore
NewMockObjectStore creates a new mock instance.
func (*MockObjectStore) EXPECT ¶
func (m *MockObjectStore) EXPECT() *MockObjectStoreMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockObjectStore) Get ¶
func (m *MockObjectStore) Get(key string) []byte
Get mocks base method.
func (*MockObjectStore) Put ¶
func (m *MockObjectStore) Put(key string, value []byte)
Put mocks base method.
type MockObjectStoreGetCall ¶
MockObjectStoreGetCall wrap *gomock.Call
func (*MockObjectStoreGetCall) Do ¶
func (c *MockObjectStoreGetCall) Do(f func(string) []byte) *MockObjectStoreGetCall
Do rewrite *gomock.Call.Do
func (*MockObjectStoreGetCall) DoAndReturn ¶
func (c *MockObjectStoreGetCall) DoAndReturn(f func(string) []byte) *MockObjectStoreGetCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockObjectStoreGetCall) Return ¶
func (c *MockObjectStoreGetCall) Return(arg0 []byte) *MockObjectStoreGetCall
Return rewrite *gomock.Call.Return
type MockObjectStoreMockRecorder ¶
type MockObjectStoreMockRecorder struct {
// contains filtered or unexported fields
}
MockObjectStoreMockRecorder is the mock recorder for MockObjectStore.
func (*MockObjectStoreMockRecorder) Get ¶
func (mr *MockObjectStoreMockRecorder) Get(key any) *MockObjectStoreGetCall
Get indicates an expected call of Get.
func (*MockObjectStoreMockRecorder) Put ¶
func (mr *MockObjectStoreMockRecorder) Put(key, value any) *MockObjectStorePutCall
Put indicates an expected call of Put.
type MockObjectStorePutCall ¶
MockObjectStorePutCall wrap *gomock.Call
func (*MockObjectStorePutCall) Do ¶
func (c *MockObjectStorePutCall) Do(f func(string, []byte)) *MockObjectStorePutCall
Do rewrite *gomock.Call.Do
func (*MockObjectStorePutCall) DoAndReturn ¶
func (c *MockObjectStorePutCall) DoAndReturn(f func(string, []byte)) *MockObjectStorePutCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockObjectStorePutCall) Return ¶
func (c *MockObjectStorePutCall) Return() *MockObjectStorePutCall
Return rewrite *gomock.Call.Return
type MockPostStore ¶
type MockPostStore struct {
// contains filtered or unexported fields
}
MockPostStore is a mock of PostStore interface.
func NewMockPostStore ¶
func NewMockPostStore(ctrl *gomock.Controller) *MockPostStore
NewMockPostStore creates a new mock instance.
func (*MockPostStore) Delete ¶
func (m *MockPostStore) Delete(ID meta.PostID) error
Delete mocks base method.
func (*MockPostStore) EXPECT ¶
func (m *MockPostStore) EXPECT() *MockPostStoreMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockPostStoreDeleteCall ¶
MockPostStoreDeleteCall wrap *gomock.Call
func (*MockPostStoreDeleteCall) Do ¶
func (c *MockPostStoreDeleteCall) Do(f func(meta.PostID) error) *MockPostStoreDeleteCall
Do rewrite *gomock.Call.Do
func (*MockPostStoreDeleteCall) DoAndReturn ¶
func (c *MockPostStoreDeleteCall) DoAndReturn(f func(meta.PostID) error) *MockPostStoreDeleteCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockPostStoreDeleteCall) Return ¶
func (c *MockPostStoreDeleteCall) Return(arg0 error) *MockPostStoreDeleteCall
Return rewrite *gomock.Call.Return
type MockPostStoreGetCall ¶
MockPostStoreGetCall wrap *gomock.Call
func (*MockPostStoreGetCall) Do ¶
func (c *MockPostStoreGetCall) Do(f func(meta.PostID) (*meta.Post, error)) *MockPostStoreGetCall
Do rewrite *gomock.Call.Do
func (*MockPostStoreGetCall) DoAndReturn ¶
func (c *MockPostStoreGetCall) DoAndReturn(f func(meta.PostID) (*meta.Post, error)) *MockPostStoreGetCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockPostStoreGetCall) Return ¶
func (c *MockPostStoreGetCall) Return(arg0 *meta.Post, arg1 error) *MockPostStoreGetCall
Return rewrite *gomock.Call.Return
type MockPostStoreListCall ¶
MockPostStoreListCall wrap *gomock.Call
func (*MockPostStoreListCall) Do ¶
func (c *MockPostStoreListCall) Do(f func(int, int) ([]*meta.Post, error)) *MockPostStoreListCall
Do rewrite *gomock.Call.Do
func (*MockPostStoreListCall) DoAndReturn ¶
func (c *MockPostStoreListCall) DoAndReturn(f func(int, int) ([]*meta.Post, error)) *MockPostStoreListCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockPostStoreListCall) Return ¶
func (c *MockPostStoreListCall) Return(arg0 []*meta.Post, arg1 error) *MockPostStoreListCall
Return rewrite *gomock.Call.Return
type MockPostStoreMockRecorder ¶
type MockPostStoreMockRecorder struct {
// contains filtered or unexported fields
}
MockPostStoreMockRecorder is the mock recorder for MockPostStore.
func (*MockPostStoreMockRecorder) Delete ¶
func (mr *MockPostStoreMockRecorder) Delete(ID any) *MockPostStoreDeleteCall
Delete indicates an expected call of Delete.
func (*MockPostStoreMockRecorder) Get ¶
func (mr *MockPostStoreMockRecorder) Get(ID any) *MockPostStoreGetCall
Get indicates an expected call of Get.
func (*MockPostStoreMockRecorder) List ¶
func (mr *MockPostStoreMockRecorder) List(offset, limit any) *MockPostStoreListCall
List indicates an expected call of List.
func (*MockPostStoreMockRecorder) Put ¶
func (mr *MockPostStoreMockRecorder) Put(ID, post any) *MockPostStorePutCall
Put indicates an expected call of Put.
type MockPostStorePutCall ¶
MockPostStorePutCall wrap *gomock.Call
func (*MockPostStorePutCall) Do ¶
func (c *MockPostStorePutCall) Do(f func(meta.PostID, *meta.Post) error) *MockPostStorePutCall
Do rewrite *gomock.Call.Do
func (*MockPostStorePutCall) DoAndReturn ¶
func (c *MockPostStorePutCall) DoAndReturn(f func(meta.PostID, *meta.Post) error) *MockPostStorePutCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockPostStorePutCall) Return ¶
func (c *MockPostStorePutCall) Return(arg0 error) *MockPostStorePutCall
Return rewrite *gomock.Call.Return
type MockStringer ¶
type MockStringer struct {
// contains filtered or unexported fields
}
MockStringer is a mock of Stringer interface.
func NewMockStringer ¶
func NewMockStringer(ctrl *gomock.Controller) *MockStringer
NewMockStringer creates a new mock instance.
func (*MockStringer) EXPECT ¶
func (m *MockStringer) EXPECT() *MockStringerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockStringer) String ¶
func (m *MockStringer) String() (string, error)
String mocks base method.
type MockStringerLoadCall ¶
MockStringerLoadCall wrap *gomock.Call
func (*MockStringerLoadCall) Do ¶
func (c *MockStringerLoadCall) Do(f func(string) error) *MockStringerLoadCall
Do rewrite *gomock.Call.Do
func (*MockStringerLoadCall) DoAndReturn ¶
func (c *MockStringerLoadCall) DoAndReturn(f func(string) error) *MockStringerLoadCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockStringerLoadCall) Return ¶
func (c *MockStringerLoadCall) Return(arg0 error) *MockStringerLoadCall
Return rewrite *gomock.Call.Return
type MockStringerMockRecorder ¶
type MockStringerMockRecorder struct {
// contains filtered or unexported fields
}
MockStringerMockRecorder is the mock recorder for MockStringer.
func (*MockStringerMockRecorder) Load ¶
func (mr *MockStringerMockRecorder) Load(arg0 any) *MockStringerLoadCall
Load indicates an expected call of Load.
func (*MockStringerMockRecorder) String ¶
func (mr *MockStringerMockRecorder) String() *MockStringerStringCall
String indicates an expected call of String.
type MockStringerStringCall ¶
MockStringerStringCall wrap *gomock.Call
func (*MockStringerStringCall) Do ¶
func (c *MockStringerStringCall) Do(f func() (string, error)) *MockStringerStringCall
Do rewrite *gomock.Call.Do
func (*MockStringerStringCall) DoAndReturn ¶
func (c *MockStringerStringCall) DoAndReturn(f func() (string, error)) *MockStringerStringCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockStringerStringCall) Return ¶
func (c *MockStringerStringCall) Return(arg0 string, arg1 error) *MockStringerStringCall
Return rewrite *gomock.Call.Return
type MockUserStore ¶
type MockUserStore struct {
// contains filtered or unexported fields
}
MockUserStore is a mock of UserStore interface.
func NewMockUserStore ¶
func NewMockUserStore(ctrl *gomock.Controller) *MockUserStore
NewMockUserStore creates a new mock instance.
func (*MockUserStore) Delete ¶
func (m *MockUserStore) Delete(ID meta.UserID) error
Delete mocks base method.
func (*MockUserStore) EXPECT ¶
func (m *MockUserStore) EXPECT() *MockUserStoreMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockUserStoreDeleteCall ¶
MockUserStoreDeleteCall wrap *gomock.Call
func (*MockUserStoreDeleteCall) Do ¶
func (c *MockUserStoreDeleteCall) Do(f func(meta.UserID) error) *MockUserStoreDeleteCall
Do rewrite *gomock.Call.Do
func (*MockUserStoreDeleteCall) DoAndReturn ¶
func (c *MockUserStoreDeleteCall) DoAndReturn(f func(meta.UserID) error) *MockUserStoreDeleteCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockUserStoreDeleteCall) Return ¶
func (c *MockUserStoreDeleteCall) Return(arg0 error) *MockUserStoreDeleteCall
Return rewrite *gomock.Call.Return
type MockUserStoreGetCall ¶
MockUserStoreGetCall wrap *gomock.Call
func (*MockUserStoreGetCall) Do ¶
func (c *MockUserStoreGetCall) Do(f func(meta.UserID) (*meta.User, error)) *MockUserStoreGetCall
Do rewrite *gomock.Call.Do
func (*MockUserStoreGetCall) DoAndReturn ¶
func (c *MockUserStoreGetCall) DoAndReturn(f func(meta.UserID) (*meta.User, error)) *MockUserStoreGetCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockUserStoreGetCall) Return ¶
func (c *MockUserStoreGetCall) Return(arg0 *meta.User, arg1 error) *MockUserStoreGetCall
Return rewrite *gomock.Call.Return
type MockUserStoreListCall ¶
MockUserStoreListCall wrap *gomock.Call
func (*MockUserStoreListCall) Do ¶
func (c *MockUserStoreListCall) Do(f func(int, int) ([]*meta.User, error)) *MockUserStoreListCall
Do rewrite *gomock.Call.Do
func (*MockUserStoreListCall) DoAndReturn ¶
func (c *MockUserStoreListCall) DoAndReturn(f func(int, int) ([]*meta.User, error)) *MockUserStoreListCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockUserStoreListCall) Return ¶
func (c *MockUserStoreListCall) Return(arg0 []*meta.User, arg1 error) *MockUserStoreListCall
Return rewrite *gomock.Call.Return
type MockUserStoreMockRecorder ¶
type MockUserStoreMockRecorder struct {
// contains filtered or unexported fields
}
MockUserStoreMockRecorder is the mock recorder for MockUserStore.
func (*MockUserStoreMockRecorder) Delete ¶
func (mr *MockUserStoreMockRecorder) Delete(ID any) *MockUserStoreDeleteCall
Delete indicates an expected call of Delete.
func (*MockUserStoreMockRecorder) Get ¶
func (mr *MockUserStoreMockRecorder) Get(ID any) *MockUserStoreGetCall
Get indicates an expected call of Get.
func (*MockUserStoreMockRecorder) List ¶
func (mr *MockUserStoreMockRecorder) List(offset, limit any) *MockUserStoreListCall
List indicates an expected call of List.
func (*MockUserStoreMockRecorder) Put ¶
func (mr *MockUserStoreMockRecorder) Put(ID, user any) *MockUserStorePutCall
Put indicates an expected call of Put.
type MockUserStorePutCall ¶
MockUserStorePutCall wrap *gomock.Call
func (*MockUserStorePutCall) Do ¶
func (c *MockUserStorePutCall) Do(f func(meta.UserID, *meta.User) error) *MockUserStorePutCall
Do rewrite *gomock.Call.Do
func (*MockUserStorePutCall) DoAndReturn ¶
func (c *MockUserStorePutCall) DoAndReturn(f func(meta.UserID, *meta.User) error) *MockUserStorePutCall
DoAndReturn rewrite *gomock.Call.DoAndReturn
func (*MockUserStorePutCall) Return ¶
func (c *MockUserStorePutCall) Return(arg0 error) *MockUserStorePutCall
Return rewrite *gomock.Call.Return
type ObjectStore ¶
type UserStore ¶
type UserStore interface { Put(ID meta.UserID, user *meta.User) error Get(ID meta.UserID) (*meta.User, error) Delete(ID meta.UserID) error // List returns a list of users with offset and limit // offset is the starting index of the list // limit is the maximum number of users to return, 0 means no limit List(offset, limit int) ([]*meta.User, error) }