Documentation
¶
Index ¶
- Variables
- type DecimalValue
- func (*DecimalValue) Descriptor() ([]byte, []int)deprecated
- func (x *DecimalValue) GetNanos() int32
- func (x *DecimalValue) GetUnits() int64
- func (*DecimalValue) ProtoMessage()
- func (x *DecimalValue) ProtoReflect() protoreflect.Message
- func (x *DecimalValue) Reset()
- func (x *DecimalValue) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_custom_CustomTypes_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type DecimalValue ¶
type DecimalValue struct {
// Whole units part of the amount
Units int64 `protobuf:"varint,1,opt,name=units,proto3" json:"units,omitempty"`
// Nano units of the amount (10^-9)
// Must be same sign as units
Nanos int32 `protobuf:"fixed32,2,opt,name=nanos,proto3" json:"nanos,omitempty"`
// contains filtered or unexported fields
}
https://learn.microsoft.com/en-us/dotnet/architecture/grpc-for-wcf-developers/protobuf-data-types#creating-a-custom-decimal-type-for-protobuf Example: 12345.6789 -> { units = 12345, nanos = 678900000 }
func (*DecimalValue) Descriptor
deprecated
func (*DecimalValue) Descriptor() ([]byte, []int)
Deprecated: Use DecimalValue.ProtoReflect.Descriptor instead.
func (*DecimalValue) GetNanos ¶
func (x *DecimalValue) GetNanos() int32
func (*DecimalValue) GetUnits ¶
func (x *DecimalValue) GetUnits() int64
func (*DecimalValue) ProtoMessage ¶
func (*DecimalValue) ProtoMessage()
func (*DecimalValue) ProtoReflect ¶
func (x *DecimalValue) ProtoReflect() protoreflect.Message
func (*DecimalValue) Reset ¶
func (x *DecimalValue) Reset()
func (*DecimalValue) String ¶
func (x *DecimalValue) String() string
Click to show internal directories.
Click to hide internal directories.