Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sidecar
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
link33
sidecar
Commits
bf12b436
Commit
bf12b436
authored
Sep 22, 2021
by
suyanlong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update hub client interface
parent
8c74ffdc
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
client.go
hub/client/client.go
+2
-2
mock_client.go
hub/client/mock_client/mock_client.go
+14
-0
No files found.
hub/client/client.go
View file @
bf12b436
...
@@ -6,6 +6,7 @@ import (
...
@@ -6,6 +6,7 @@ import (
"github.com/meshplus/bitxhub-kit/crypto"
"github.com/meshplus/bitxhub-kit/crypto"
"github.com/meshplus/bitxhub-kit/types"
"github.com/meshplus/bitxhub-kit/types"
"github.com/link33/sidecar/internal"
"github.com/link33/sidecar/model/pb"
"github.com/link33/sidecar/model/pb"
)
)
...
@@ -17,8 +18,7 @@ const (
...
@@ -17,8 +18,7 @@ const (
//go:generate mockgen -destination mock_client/mock_client.go -package mock_client -source client.go
//go:generate mockgen -destination mock_client/mock_client.go -package mock_client -source client.go
type
Client
interface
{
type
Client
interface
{
// Close all connections between link33 and the client.
internal
.
Launcher
Stop
()
error
// Reset ecdsa key.
// Reset ecdsa key.
SetPrivateKey
(
crypto
.
PrivateKey
)
SetPrivateKey
(
crypto
.
PrivateKey
)
...
...
hub/client/mock_client/mock_client.go
View file @
bf12b436
...
@@ -518,6 +518,20 @@ func (mr *MockClientMockRecorder) SetPrivateKey(arg0 interface{}) *gomock.Call {
...
@@ -518,6 +518,20 @@ func (mr *MockClientMockRecorder) SetPrivateKey(arg0 interface{}) *gomock.Call {
return
mr
.
mock
.
ctrl
.
RecordCallWithMethodType
(
mr
.
mock
,
"SetPrivateKey"
,
reflect
.
TypeOf
((
*
MockClient
)(
nil
)
.
SetPrivateKey
),
arg0
)
return
mr
.
mock
.
ctrl
.
RecordCallWithMethodType
(
mr
.
mock
,
"SetPrivateKey"
,
reflect
.
TypeOf
((
*
MockClient
)(
nil
)
.
SetPrivateKey
),
arg0
)
}
}
// Start mocks base method.
func
(
m
*
MockClient
)
Start
()
error
{
m
.
ctrl
.
T
.
Helper
()
ret
:=
m
.
ctrl
.
Call
(
m
,
"Start"
)
ret0
,
_
:=
ret
[
0
]
.
(
error
)
return
ret0
}
// Start indicates an expected call of Start.
func
(
mr
*
MockClientMockRecorder
)
Start
()
*
gomock
.
Call
{
mr
.
mock
.
ctrl
.
T
.
Helper
()
return
mr
.
mock
.
ctrl
.
RecordCallWithMethodType
(
mr
.
mock
,
"Start"
,
reflect
.
TypeOf
((
*
MockClient
)(
nil
)
.
Start
))
}
// Stop mocks base method.
// Stop mocks base method.
func
(
m
*
MockClient
)
Stop
()
error
{
func
(
m
*
MockClient
)
Stop
()
error
{
m
.
ctrl
.
T
.
Helper
()
m
.
ctrl
.
T
.
Helper
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment