mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-11-15 04:25:27 +00:00
94914d4ca1
- Add necessary types to track account fractional balances. - Add FractionalBalance type to genesis
35 lines
1.1 KiB
Protocol Buffer
35 lines
1.1 KiB
Protocol Buffer
syntax = "proto3";
|
|
package kava.precisebank.v1;
|
|
|
|
import "cosmos_proto/cosmos.proto";
|
|
import "gogoproto/gogo.proto";
|
|
|
|
option go_package = "github.com/kava-labs/kava/x/precisebank/types";
|
|
|
|
// GenesisState defines the precisebank module's genesis state.
|
|
message GenesisState {
|
|
// balances is a list of all the balances in the precisebank module.
|
|
repeated FractionalBalance balances = 1 [
|
|
(gogoproto.castrepeated) = "FractionalBalances",
|
|
(gogoproto.nullable) = false
|
|
];
|
|
}
|
|
|
|
// FractionalBalance defines the fractional portion of an account balance
|
|
message FractionalBalance {
|
|
option (gogoproto.equal) = false;
|
|
option (gogoproto.goproto_getters) = false;
|
|
|
|
// address is the address of the balance holder.
|
|
string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"];
|
|
|
|
// amount indicates amount of only the fractional balance owned by the
|
|
// address. FractionalBalance currently only supports tracking 1 single asset,
|
|
// e.g. fractional balances of ukava.
|
|
string amount = 2 [
|
|
(cosmos_proto.scalar) = "cosmos.Int",
|
|
(gogoproto.customtype) = "cosmossdk.io/math.Int",
|
|
(gogoproto.nullable) = false
|
|
];
|
|
}
|