ce3cfbd457
* Update proto files * Update script to generate typescript definitions * Generate typescript definitions from protobuf files * Cleanup unnecessary proto files --------- Co-authored-by: neeraj <neeraj.rtly@gmail.com>
62 lines
1.8 KiB
Protocol Buffer
62 lines
1.8 KiB
Protocol Buffer
syntax = "proto3";
|
|
package cosmos.base.v1beta1;
|
|
|
|
import "gogoproto/gogo.proto";
|
|
import "cosmos_proto/cosmos.proto";
|
|
import "amino/amino.proto";
|
|
|
|
option go_package = "github.com/cosmos/cosmos-sdk/types";
|
|
option (gogoproto.goproto_stringer_all) = false;
|
|
option (gogoproto.stringer_all) = false;
|
|
|
|
// Coin defines a token with a denomination and an amount.
|
|
//
|
|
// NOTE: The amount field is an Int which implements the custom method
|
|
// signatures required by gogoproto.
|
|
message Coin {
|
|
option (gogoproto.equal) = true;
|
|
|
|
string denom = 1;
|
|
string amount = 2 [
|
|
(cosmos_proto.scalar) = "cosmos.Int",
|
|
(gogoproto.customtype) = "cosmossdk.io/math.Int",
|
|
(gogoproto.nullable) = false,
|
|
(amino.dont_omitempty) = true
|
|
];
|
|
}
|
|
|
|
// DecCoin defines a token with a denomination and a decimal amount.
|
|
//
|
|
// NOTE: The amount field is an Dec which implements the custom method
|
|
// signatures required by gogoproto.
|
|
message DecCoin {
|
|
option (gogoproto.equal) = true;
|
|
|
|
string denom = 1;
|
|
string amount = 2 [
|
|
(cosmos_proto.scalar) = "cosmos.Dec",
|
|
(gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
|
|
(gogoproto.nullable) = false
|
|
];
|
|
}
|
|
|
|
// IntProto defines a Protobuf wrapper around an Int object.
|
|
// Deprecated: Prefer to use math.Int directly. It supports binary Marshal and Unmarshal.
|
|
message IntProto {
|
|
string int = 1 [
|
|
(cosmos_proto.scalar) = "cosmos.Int",
|
|
(gogoproto.customtype) = "cosmossdk.io/math.Int",
|
|
(gogoproto.nullable) = false
|
|
];
|
|
}
|
|
|
|
// DecProto defines a Protobuf wrapper around a Dec object.
|
|
// Deprecated: Prefer to use math.LegacyDec directly. It supports binary Marshal and Unmarshal.
|
|
message DecProto {
|
|
string dec = 1 [
|
|
(cosmos_proto.scalar) = "cosmos.Dec",
|
|
(gogoproto.customtype) = "cosmossdk.io/math.LegacyDec",
|
|
(gogoproto.nullable) = false
|
|
];
|
|
}
|