chainv1alpha1

package
v2.5.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 28, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthChain        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowChain          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupChain = fmt.Errorf("proto: unexpected end of group")
)

Functions

func RegisterQueryServiceServer

func RegisterQueryServiceServer(s grpc1.Server, srv QueryServiceServer)

Types

type ChainParameters

type ChainParameters struct {
	// The identifier of the chain.
	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
	// The duration of each epoch, in number of blocks.
	EpochDuration uint64 `protobuf:"varint,2,opt,name=epoch_duration,json=epochDuration,proto3" json:"epoch_duration,omitempty"`
}

Global chain configuration data, such as chain ID, epoch duration, etc.

func (*ChainParameters) Descriptor

func (*ChainParameters) Descriptor() ([]byte, []int)

func (*ChainParameters) GetChainId

func (m *ChainParameters) GetChainId() string

func (*ChainParameters) GetEpochDuration

func (m *ChainParameters) GetEpochDuration() uint64

func (*ChainParameters) Marshal

func (m *ChainParameters) Marshal() (dAtA []byte, err error)

func (*ChainParameters) MarshalTo

func (m *ChainParameters) MarshalTo(dAtA []byte) (int, error)

func (*ChainParameters) MarshalToSizedBuffer

func (m *ChainParameters) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ChainParameters) ProtoMessage

func (*ChainParameters) ProtoMessage()

func (*ChainParameters) Reset

func (m *ChainParameters) Reset()

func (*ChainParameters) Size

func (m *ChainParameters) Size() (n int)

func (*ChainParameters) String

func (m *ChainParameters) String() string

func (*ChainParameters) Unmarshal

func (m *ChainParameters) Unmarshal(dAtA []byte) error

func (*ChainParameters) XXX_DiscardUnknown

func (m *ChainParameters) XXX_DiscardUnknown()

func (*ChainParameters) XXX_Marshal

func (m *ChainParameters) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ChainParameters) XXX_Merge

func (m *ChainParameters) XXX_Merge(src proto.Message)

func (*ChainParameters) XXX_Size

func (m *ChainParameters) XXX_Size() int

func (*ChainParameters) XXX_Unmarshal

func (m *ChainParameters) XXX_Unmarshal(b []byte) error

type Epoch

type Epoch struct {
	Index       uint64 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"`
	StartHeight uint64 `protobuf:"varint,2,opt,name=start_height,json=startHeight,proto3" json:"start_height,omitempty"`
}

func (*Epoch) Descriptor

func (*Epoch) Descriptor() ([]byte, []int)

func (*Epoch) GetIndex

func (m *Epoch) GetIndex() uint64

func (*Epoch) GetStartHeight

func (m *Epoch) GetStartHeight() uint64

func (*Epoch) Marshal

func (m *Epoch) Marshal() (dAtA []byte, err error)

func (*Epoch) MarshalTo

func (m *Epoch) MarshalTo(dAtA []byte) (int, error)

func (*Epoch) MarshalToSizedBuffer

func (m *Epoch) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Epoch) ProtoMessage

func (*Epoch) ProtoMessage()

func (*Epoch) Reset

func (m *Epoch) Reset()

func (*Epoch) Size

func (m *Epoch) Size() (n int)

func (*Epoch) String

func (m *Epoch) String() string

func (*Epoch) Unmarshal

func (m *Epoch) Unmarshal(dAtA []byte) error

func (*Epoch) XXX_DiscardUnknown

func (m *Epoch) XXX_DiscardUnknown()

func (*Epoch) XXX_Marshal

func (m *Epoch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Epoch) XXX_Merge

func (m *Epoch) XXX_Merge(src proto.Message)

func (*Epoch) XXX_Size

func (m *Epoch) XXX_Size() int

func (*Epoch) XXX_Unmarshal

func (m *Epoch) XXX_Unmarshal(b []byte) error

type EpochByHeightRequest

type EpochByHeightRequest struct {
	Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
}

func (*EpochByHeightRequest) Descriptor

func (*EpochByHeightRequest) Descriptor() ([]byte, []int)

func (*EpochByHeightRequest) GetHeight

func (m *EpochByHeightRequest) GetHeight() uint64

func (*EpochByHeightRequest) Marshal

func (m *EpochByHeightRequest) Marshal() (dAtA []byte, err error)

func (*EpochByHeightRequest) MarshalTo

func (m *EpochByHeightRequest) MarshalTo(dAtA []byte) (int, error)

func (*EpochByHeightRequest) MarshalToSizedBuffer

func (m *EpochByHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EpochByHeightRequest) ProtoMessage

func (*EpochByHeightRequest) ProtoMessage()

func (*EpochByHeightRequest) Reset

func (m *EpochByHeightRequest) Reset()

func (*EpochByHeightRequest) Size

func (m *EpochByHeightRequest) Size() (n int)

func (*EpochByHeightRequest) String

func (m *EpochByHeightRequest) String() string

func (*EpochByHeightRequest) Unmarshal

func (m *EpochByHeightRequest) Unmarshal(dAtA []byte) error

func (*EpochByHeightRequest) XXX_DiscardUnknown

func (m *EpochByHeightRequest) XXX_DiscardUnknown()

func (*EpochByHeightRequest) XXX_Marshal

func (m *EpochByHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EpochByHeightRequest) XXX_Merge

func (m *EpochByHeightRequest) XXX_Merge(src proto.Message)

func (*EpochByHeightRequest) XXX_Size

func (m *EpochByHeightRequest) XXX_Size() int

func (*EpochByHeightRequest) XXX_Unmarshal

func (m *EpochByHeightRequest) XXX_Unmarshal(b []byte) error

type EpochByHeightResponse

type EpochByHeightResponse struct {
	Epoch *Epoch `protobuf:"bytes,1,opt,name=epoch,proto3" json:"epoch,omitempty"`
}

func (*EpochByHeightResponse) Descriptor

func (*EpochByHeightResponse) Descriptor() ([]byte, []int)

func (*EpochByHeightResponse) GetEpoch

func (m *EpochByHeightResponse) GetEpoch() *Epoch

func (*EpochByHeightResponse) Marshal

func (m *EpochByHeightResponse) Marshal() (dAtA []byte, err error)

func (*EpochByHeightResponse) MarshalTo

func (m *EpochByHeightResponse) MarshalTo(dAtA []byte) (int, error)

func (*EpochByHeightResponse) MarshalToSizedBuffer

func (m *EpochByHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*EpochByHeightResponse) ProtoMessage

func (*EpochByHeightResponse) ProtoMessage()

func (*EpochByHeightResponse) Reset

func (m *EpochByHeightResponse) Reset()

func (*EpochByHeightResponse) Size

func (m *EpochByHeightResponse) Size() (n int)

func (*EpochByHeightResponse) String

func (m *EpochByHeightResponse) String() string

func (*EpochByHeightResponse) Unmarshal

func (m *EpochByHeightResponse) Unmarshal(dAtA []byte) error

func (*EpochByHeightResponse) XXX_DiscardUnknown

func (m *EpochByHeightResponse) XXX_DiscardUnknown()

func (*EpochByHeightResponse) XXX_Marshal

func (m *EpochByHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EpochByHeightResponse) XXX_Merge

func (m *EpochByHeightResponse) XXX_Merge(src proto.Message)

func (*EpochByHeightResponse) XXX_Size

func (m *EpochByHeightResponse) XXX_Size() int

func (*EpochByHeightResponse) XXX_Unmarshal

func (m *EpochByHeightResponse) XXX_Unmarshal(b []byte) error

type FmdParameters

type FmdParameters struct {
	PrecisionBits   uint32 `protobuf:"varint,1,opt,name=precision_bits,json=precisionBits,proto3" json:"precision_bits,omitempty"`
	AsOfBlockHeight uint64 `protobuf:"varint,2,opt,name=as_of_block_height,json=asOfBlockHeight,proto3" json:"as_of_block_height,omitempty"`
}

Parameters for Fuzzy Message Detection

func (*FmdParameters) Descriptor

func (*FmdParameters) Descriptor() ([]byte, []int)

func (*FmdParameters) GetAsOfBlockHeight

func (m *FmdParameters) GetAsOfBlockHeight() uint64

func (*FmdParameters) GetPrecisionBits

func (m *FmdParameters) GetPrecisionBits() uint32

func (*FmdParameters) Marshal

func (m *FmdParameters) Marshal() (dAtA []byte, err error)

func (*FmdParameters) MarshalTo

func (m *FmdParameters) MarshalTo(dAtA []byte) (int, error)

func (*FmdParameters) MarshalToSizedBuffer

func (m *FmdParameters) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*FmdParameters) ProtoMessage

func (*FmdParameters) ProtoMessage()

func (*FmdParameters) Reset

func (m *FmdParameters) Reset()

func (*FmdParameters) Size

func (m *FmdParameters) Size() (n int)

func (*FmdParameters) String

func (m *FmdParameters) String() string

func (*FmdParameters) Unmarshal

func (m *FmdParameters) Unmarshal(dAtA []byte) error

func (*FmdParameters) XXX_DiscardUnknown

func (m *FmdParameters) XXX_DiscardUnknown()

func (*FmdParameters) XXX_Marshal

func (m *FmdParameters) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*FmdParameters) XXX_Merge

func (m *FmdParameters) XXX_Merge(src proto.Message)

func (*FmdParameters) XXX_Size

func (m *FmdParameters) XXX_Size() int

func (*FmdParameters) XXX_Unmarshal

func (m *FmdParameters) XXX_Unmarshal(b []byte) error

type GenesisContent

type GenesisContent struct {
	// The ChainParameters present at genesis.
	ChainParams *ChainParameters `protobuf:"bytes,1,opt,name=chain_params,json=chainParams,proto3" json:"chain_params,omitempty"`
}

Chain-specific genesis content.

func (*GenesisContent) Descriptor

func (*GenesisContent) Descriptor() ([]byte, []int)

func (*GenesisContent) GetChainParams

func (m *GenesisContent) GetChainParams() *ChainParameters

func (*GenesisContent) Marshal

func (m *GenesisContent) Marshal() (dAtA []byte, err error)

func (*GenesisContent) MarshalTo

func (m *GenesisContent) MarshalTo(dAtA []byte) (int, error)

func (*GenesisContent) MarshalToSizedBuffer

func (m *GenesisContent) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*GenesisContent) ProtoMessage

func (*GenesisContent) ProtoMessage()

func (*GenesisContent) Reset

func (m *GenesisContent) Reset()

func (*GenesisContent) Size

func (m *GenesisContent) Size() (n int)

func (*GenesisContent) String

func (m *GenesisContent) String() string

func (*GenesisContent) Unmarshal

func (m *GenesisContent) Unmarshal(dAtA []byte) error

func (*GenesisContent) XXX_DiscardUnknown

func (m *GenesisContent) XXX_DiscardUnknown()

func (*GenesisContent) XXX_Marshal

func (m *GenesisContent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GenesisContent) XXX_Merge

func (m *GenesisContent) XXX_Merge(src proto.Message)

func (*GenesisContent) XXX_Size

func (m *GenesisContent) XXX_Size() int

func (*GenesisContent) XXX_Unmarshal

func (m *GenesisContent) XXX_Unmarshal(b []byte) error

type QueryServiceClient

type QueryServiceClient interface {
	// TODO: move to SCT cf sct/src/component/view.rs:9 "make epoch management the responsibility of this component"
	EpochByHeight(ctx context.Context, in *EpochByHeightRequest, opts ...grpc.CallOption) (*EpochByHeightResponse, error)
}

QueryServiceClient is the client API for QueryService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewQueryServiceClient

func NewQueryServiceClient(cc grpc1.ClientConn) QueryServiceClient

type QueryServiceServer

type QueryServiceServer interface {
	// TODO: move to SCT cf sct/src/component/view.rs:9 "make epoch management the responsibility of this component"
	EpochByHeight(context.Context, *EpochByHeightRequest) (*EpochByHeightResponse, error)
}

QueryServiceServer is the server API for QueryService service.

type Ratio

type Ratio struct {
	// The numerator.
	Numerator uint64 `protobuf:"varint,1,opt,name=numerator,proto3" json:"numerator,omitempty"`
	// The denominator.
	Denominator uint64 `protobuf:"varint,2,opt,name=denominator,proto3" json:"denominator,omitempty"`
}

The ratio between two numbers, used in governance to describe vote thresholds and quorums.

func (*Ratio) Descriptor

func (*Ratio) Descriptor() ([]byte, []int)

func (*Ratio) GetDenominator

func (m *Ratio) GetDenominator() uint64

func (*Ratio) GetNumerator

func (m *Ratio) GetNumerator() uint64

func (*Ratio) Marshal

func (m *Ratio) Marshal() (dAtA []byte, err error)

func (*Ratio) MarshalTo

func (m *Ratio) MarshalTo(dAtA []byte) (int, error)

func (*Ratio) MarshalToSizedBuffer

func (m *Ratio) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Ratio) ProtoMessage

func (*Ratio) ProtoMessage()

func (*Ratio) Reset

func (m *Ratio) Reset()

func (*Ratio) Size

func (m *Ratio) Size() (n int)

func (*Ratio) String

func (m *Ratio) String() string

func (*Ratio) Unmarshal

func (m *Ratio) Unmarshal(dAtA []byte) error

func (*Ratio) XXX_DiscardUnknown

func (m *Ratio) XXX_DiscardUnknown()

func (*Ratio) XXX_Marshal

func (m *Ratio) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Ratio) XXX_Merge

func (m *Ratio) XXX_Merge(src proto.Message)

func (*Ratio) XXX_Size

func (m *Ratio) XXX_Size() int

func (*Ratio) XXX_Unmarshal

func (m *Ratio) XXX_Unmarshal(b []byte) error

type UnimplementedQueryServiceServer

type UnimplementedQueryServiceServer struct {
}

UnimplementedQueryServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServiceServer) EpochByHeight

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL