Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
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
exchain
nebula
Commits
0e07951f
Commit
0e07951f
authored
Feb 08, 2025
by
vicotor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update proto
parent
8f577bdc
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
116 additions
and
37 deletions
+116
-37
buf.lock
exchain/protocol/buf.lock
+7
-0
buf.yaml
exchain/protocol/buf.yaml
+2
-0
account.pb.go
exchain/protocol/gen/go/nebula/v1/account.pb.go
+99
-35
account.proto
exchain/protocol/proto/nebula/v1/account.proto
+8
-2
No files found.
exchain/protocol/buf.lock
0 → 100644
View file @
0e07951f
# Generated by buf. DO NOT EDIT.
version: v1
deps:
- remote: buf.build
owner: bufbuild
repository: protovalidate
commit: 63bb56e204954558946a641ef0d68910
exchain/protocol/buf.yaml
View file @
0e07951f
version
:
v1
deps
:
-
buf.build/bufbuild/protovalidate
breaking
:
use
:
-
FILE
...
...
exchain/protocol/gen/go/nebula/v1/account.pb.go
View file @
0e07951f
...
...
@@ -22,6 +22,52 @@ const (
_
=
protoimpl
.
EnforceVersion
(
protoimpl
.
MaxVersion
-
20
)
)
type
WalletType
int32
const
(
WalletType_WALLET_SPOT
WalletType
=
0
WalletType_WALLET_PERP
WalletType
=
1
)
// Enum value maps for WalletType.
var
(
WalletType_name
=
map
[
int32
]
string
{
0
:
"WALLET_SPOT"
,
1
:
"WALLET_PERP"
,
}
WalletType_value
=
map
[
string
]
int32
{
"WALLET_SPOT"
:
0
,
"WALLET_PERP"
:
1
,
}
)
func
(
x
WalletType
)
Enum
()
*
WalletType
{
p
:=
new
(
WalletType
)
*
p
=
x
return
p
}
func
(
x
WalletType
)
String
()
string
{
return
protoimpl
.
X
.
EnumStringOf
(
x
.
Descriptor
(),
protoreflect
.
EnumNumber
(
x
))
}
func
(
WalletType
)
Descriptor
()
protoreflect
.
EnumDescriptor
{
return
file_nebula_v1_account_proto_enumTypes
[
0
]
.
Descriptor
()
}
func
(
WalletType
)
Type
()
protoreflect
.
EnumType
{
return
&
file_nebula_v1_account_proto_enumTypes
[
0
]
}
func
(
x
WalletType
)
Number
()
protoreflect
.
EnumNumber
{
return
protoreflect
.
EnumNumber
(
x
)
}
// Deprecated: Use WalletType.Descriptor instead.
func
(
WalletType
)
EnumDescriptor
()
([]
byte
,
[]
int
)
{
return
file_nebula_v1_account_proto_rawDescGZIP
(),
[]
int
{
0
}
}
// define account message.
type
Account
struct
{
state
protoimpl
.
MessageState
...
...
@@ -131,8 +177,9 @@ type Wallet struct {
unknownFields
protoimpl
.
UnknownFields
Coin
string
`protobuf:"bytes,1,opt,name=coin,proto3" json:"coin,omitempty"`
Balance
[]
byte
`protobuf:"bytes,2,opt,name=balance,proto3" json:"balance,omitempty"`
FrozenBalance
[]
byte
`protobuf:"bytes,3,opt,name=frozen_balance,json=frozenBalance,proto3" json:"frozen_balance,omitempty"`
Type
WalletType
`protobuf:"varint,2,opt,name=type,proto3,enum=exchain.nebula.v1.WalletType" json:"type,omitempty"`
Balance
[]
byte
`protobuf:"bytes,3,opt,name=balance,proto3" json:"balance,omitempty"`
FrozenBalance
[]
byte
`protobuf:"bytes,4,opt,name=frozen_balance,json=frozenBalance,proto3" json:"frozen_balance,omitempty"`
}
func
(
x
*
Wallet
)
Reset
()
{
...
...
@@ -174,6 +221,13 @@ func (x *Wallet) GetCoin() string {
return
""
}
func
(
x
*
Wallet
)
GetType
()
WalletType
{
if
x
!=
nil
{
return
x
.
Type
}
return
WalletType_WALLET_SPOT
}
func
(
x
*
Wallet
)
GetBalance
()
[]
byte
{
if
x
!=
nil
{
return
x
.
Balance
...
...
@@ -208,27 +262,33 @@ var file_nebula_v1_account_proto_rawDesc = []byte{
0x07
,
0x77
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x73
,
0x18
,
0x01
,
0x20
,
0x03
,
0x28
,
0x0b
,
0x32
,
0x19
,
0x2e
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2e
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x52
,
0x07
,
0x77
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x73
,
0x22
,
0x5d
,
0x0a
,
0x06
,
0x57
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x63
,
0x6f
,
0x69
,
0x6e
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x63
,
0x6f
,
0x69
,
0x6e
,
0x12
,
0x18
,
0x0a
,
0x07
,
0x62
,
0x61
,
0x6c
,
0x61
,
0x6e
,
0x63
,
0x65
,
0x18
,
0x02
,
0x20
,
0x01
,
0x28
,
0x0c
,
0x52
,
0x07
,
0x62
,
0x61
,
0x6c
,
0x61
,
0x6e
,
0x63
,
0x65
,
0x12
,
0x25
,
0x0a
,
0x0e
,
0x66
,
0x72
,
0x6f
,
0x7a
,
0x65
,
0x6e
,
0x5f
,
0x62
,
0x61
,
0x6c
,
0x61
,
0x6e
,
0x63
,
0x65
,
0x18
,
0x03
,
0x20
,
0x01
,
0x28
,
0x0c
,
0x52
,
0x0d
,
0x66
,
0x72
,
0x6f
,
0x7a
,
0x65
,
0x6e
,
0x42
,
0x61
,
0x6c
,
0x61
,
0x6e
,
0x63
,
0x65
,
0x42
,
0xd5
,
0x01
,
0x0a
,
0x15
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2e
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2e
,
0x76
,
0x31
,
0x42
,
0x0c
,
0x41
,
0x63
,
0x63
,
0x6f
,
0x75
,
0x6e
,
0x74
,
0x50
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x48
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x2f
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2f
,
0x67
,
0x6f
,
0x2d
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2f
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x63
,
0x6f
,
0x6c
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x67
,
0x6f
,
0x2f
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2f
,
0x76
,
0x31
,
0x3b
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x76
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x45
,
0x4e
,
0x58
,
0xaa
,
0x02
,
0x11
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2e
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x11
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x5c
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x1d
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x5c
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x13
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x3a
,
0x3a
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x3a
,
0x3a
,
0x56
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
0x74
,
0x73
,
0x22
,
0x90
,
0x01
,
0x0a
,
0x06
,
0x57
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x63
,
0x6f
,
0x69
,
0x6e
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x63
,
0x6f
,
0x69
,
0x6e
,
0x12
,
0x31
,
0x0a
,
0x04
,
0x74
,
0x79
,
0x70
,
0x65
,
0x18
,
0x02
,
0x20
,
0x01
,
0x28
,
0x0e
,
0x32
,
0x1d
,
0x2e
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2e
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x61
,
0x6c
,
0x6c
,
0x65
,
0x74
,
0x54
,
0x79
,
0x70
,
0x65
,
0x52
,
0x04
,
0x74
,
0x79
,
0x70
,
0x65
,
0x12
,
0x18
,
0x0a
,
0x07
,
0x62
,
0x61
,
0x6c
,
0x61
,
0x6e
,
0x63
,
0x65
,
0x18
,
0x03
,
0x20
,
0x01
,
0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0x67
,
0x6f
,
0x2d
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2f
,
0x65
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x63
,
0x6f
,
0x6c
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x67
,
0x6f
,
0x2f
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2f
,
0x76
,
0x31
,
0x3b
,
0x6e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x76
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x45
,
0x4e
,
0x58
,
0xaa
,
0x02
,
0x11
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x2e
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x11
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x5c
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x1d
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x5c
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x13
,
0x45
,
0x78
,
0x63
,
0x68
,
0x61
,
0x69
,
0x6e
,
0x3a
,
0x3a
,
0x4e
,
0x65
,
0x62
,
0x75
,
0x6c
,
0x61
,
0x3a
,
0x3a
,
0x56
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
}
var
(
...
...
@@ -243,20 +303,23 @@ func file_nebula_v1_account_proto_rawDescGZIP() []byte {
return
file_nebula_v1_account_proto_rawDescData
}
var
file_nebula_v1_account_proto_enumTypes
=
make
([]
protoimpl
.
EnumInfo
,
1
)
var
file_nebula_v1_account_proto_msgTypes
=
make
([]
protoimpl
.
MessageInfo
,
3
)
var
file_nebula_v1_account_proto_goTypes
=
[]
interface
{}{
(
*
Account
)(
nil
),
// 0: exchain.nebula.v1.Account
(
*
WalletList
)(
nil
),
// 1: exchain.nebula.v1.WalletList
(
*
Wallet
)(
nil
),
// 2: exchain.nebula.v1.Wallet
(
WalletType
)(
0
),
// 0: exchain.nebula.v1.WalletType
(
*
Account
)(
nil
),
// 1: exchain.nebula.v1.Account
(
*
WalletList
)(
nil
),
// 2: exchain.nebula.v1.WalletList
(
*
Wallet
)(
nil
),
// 3: exchain.nebula.v1.Wallet
}
var
file_nebula_v1_account_proto_depIdxs
=
[]
int32
{
1
,
// 0: exchain.nebula.v1.Account.wallets:type_name -> exchain.nebula.v1.WalletList
2
,
// 1: exchain.nebula.v1.WalletList.wallets:type_name -> exchain.nebula.v1.Wallet
2
,
// [2:2] is the sub-list for method output_type
2
,
// [2:2] is the sub-list for method input_type
2
,
// [2:2] is the sub-list for extension type_name
2
,
// [2:2] is the sub-list for extension extendee
0
,
// [0:2] is the sub-list for field type_name
2
,
// 0: exchain.nebula.v1.Account.wallets:type_name -> exchain.nebula.v1.WalletList
3
,
// 1: exchain.nebula.v1.WalletList.wallets:type_name -> exchain.nebula.v1.Wallet
0
,
// 2: exchain.nebula.v1.Wallet.type:type_name -> exchain.nebula.v1.WalletType
3
,
// [3:3] is the sub-list for method output_type
3
,
// [3:3] is the sub-list for method input_type
3
,
// [3:3] is the sub-list for extension type_name
3
,
// [3:3] is the sub-list for extension extendee
0
,
// [0:3] is the sub-list for field type_name
}
func
init
()
{
file_nebula_v1_account_proto_init
()
}
...
...
@@ -307,13 +370,14 @@ func file_nebula_v1_account_proto_init() {
File
:
protoimpl
.
DescBuilder
{
GoPackagePath
:
reflect
.
TypeOf
(
x
{})
.
PkgPath
(),
RawDescriptor
:
file_nebula_v1_account_proto_rawDesc
,
NumEnums
:
0
,
NumEnums
:
1
,
NumMessages
:
3
,
NumExtensions
:
0
,
NumServices
:
0
,
},
GoTypes
:
file_nebula_v1_account_proto_goTypes
,
DependencyIndexes
:
file_nebula_v1_account_proto_depIdxs
,
EnumInfos
:
file_nebula_v1_account_proto_enumTypes
,
MessageInfos
:
file_nebula_v1_account_proto_msgTypes
,
}
.
Build
()
File_nebula_v1_account_proto
=
out
.
File
...
...
exchain/protocol/proto/nebula/v1/account.proto
View file @
0e07951f
...
...
@@ -22,8 +22,14 @@ message WalletList {
repeated
Wallet
wallets
=
1
;
}
enum
WalletType
{
WALLET_SPOT
=
0
;
WALLET_PERP
=
1
;
}
message
Wallet
{
string
coin
=
1
;
bytes
balance
=
2
;
bytes
frozen_balance
=
3
;
WalletType
type
=
2
;
bytes
balance
=
3
;
bytes
frozen_balance
=
4
;
}
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