Documentation ¶
Index ¶
- Variables
- func RegisterInterfaces(registry codectypes.InterfaceRegistry)
- type Chain
- func (c *Chain) ChainID() string
- func (c *Chain) ClientID() string
- func (c *Chain) Codec() codec.ProtoCodecMarshaler
- func (c *Chain) Config() ChainConfig
- func (c *Chain) Connect() error
- func (c *Chain) Contract() *gateway.Contract
- func (c *Chain) GetAddress() (sdk.AccAddress, error)
- func (c *Chain) GetLatestHeight() (int64, error)
- func (c *Chain) GetSerializedIdentity(label string) (*msppb.SerializedIdentity, error)
- func (c *Chain) Init(homePath string, timeout time.Duration, codec codec.ProtoCodecMarshaler, ...) error
- func (c *Chain) Path() *core.PathEnd
- func (c *Chain) PopulateWallet(certPath, privateKeyPath string) error
- func (c *Chain) Query(req app.RequestQuery) (*app.ResponseQuery, error)
- func (c *Chain) QueryBalance(address sdk.AccAddress) (sdk.Coins, error)
- func (c *Chain) QueryChannel(height int64) (chanRes *chantypes.QueryChannelResponse, err error)
- func (c *Chain) QueryClientConsensusState(_ int64, dstClientConsHeight ibcexported.Height) (*clienttypes.QueryConsensusStateResponse, error)
- func (c *Chain) QueryClientState(_ int64) (*clienttypes.QueryClientStateResponse, error)
- func (c *Chain) QueryConnection(_ int64) (*conntypes.QueryConnectionResponse, error)
- func (c *Chain) QueryCurrentSequence() (*commitment.Sequence, error)
- func (c *Chain) QueryDenomTraces(offset, limit uint64, height int64) (*transfertypes.QueryDenomTracesResponse, error)
- func (c *Chain) QueryPacket(_ int64, sequence uint64) (*chantypes.Packet, error)
- func (dst *Chain) QueryPacketAcknowledgement(_ int64, sequence uint64) ([]byte, error)
- func (c *Chain) QueryPacketAcknowledgementCommitment(_ int64, seq uint64) (ackRes *chantypes.QueryPacketAcknowledgementResponse, err error)
- func (c *Chain) QueryPacketAcknowledgementCommitments(offset, limit uint64, _ int64) (comRes *chantypes.QueryPacketAcknowledgementsResponse, err error)
- func (c *Chain) QueryPacketCommitment(_ int64, seq uint64) (comRes *chantypes.QueryPacketCommitmentResponse, err error)
- func (c *Chain) QueryPacketCommitments(offset, limit uint64, height int64) (comRes *chantypes.QueryPacketCommitmentsResponse, err error)
- func (c *Chain) QueryUnrecievedAcknowledgements(_ int64, seqs []uint64) ([]uint64, error)
- func (c *Chain) QueryUnrecievedPackets(height int64, seqs []uint64) ([]uint64, error)
- func (c *Chain) RegisterMsgEventListener(listener core.MsgEventListener)
- func (c *Chain) Send(msgs []sdk.Msg) bool
- func (c *Chain) SendMsgs(msgs []sdk.Msg) ([]byte, error)
- func (c *Chain) SetRelayInfo(p *core.PathEnd, _ *core.ProvableChain, _ *core.PathEnd) error
- func (c *Chain) SetupForRelay(ctx context.Context) error
- type ChainConfig
- func (c ChainConfig) Build() (core.ChainI, error)
- func (*ChainConfig) Descriptor() ([]byte, []int)
- func (m *ChainConfig) Marshal() (dAtA []byte, err error)
- func (m *ChainConfig) MarshalTo(dAtA []byte) (int, error)
- func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ChainConfig) ProtoMessage()
- func (m *ChainConfig) Reset()
- func (m *ChainConfig) Size() (n int)
- func (m *ChainConfig) String() string
- func (m *ChainConfig) Unmarshal(dAtA []byte) error
- func (m *ChainConfig) XXX_DiscardUnknown()
- func (m *ChainConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ChainConfig) XXX_Merge(src proto.Message)
- func (m *ChainConfig) XXX_Size() int
- func (m *ChainConfig) XXX_Unmarshal(b []byte) error
- type FabricGateway
- type MSPConfig
- type Prover
- func (pr *Prover) CreateMsgCreateClient(clientID string, dstHeader core.HeaderI, signer sdk.AccAddress) (*clienttypes.MsgCreateClient, error)
- func (pr *Prover) GetChainID() string
- func (pr *Prover) GetLatestLightHeight() (int64, error)
- func (pr *Prover) GetLocalMspConfigs() ([]MSPConfig, error)
- func (pr *Prover) Init(homePath string, timeout time.Duration, codec codec.ProtoCodecMarshaler, ...) error
- func (pr *Prover) QueryChannelWithProof(_ int64) (chanRes *chantypes.QueryChannelResponse, err error)
- func (pr *Prover) QueryClientConsensusStateWithProof(_ int64, dstClientConsHeight ibcexported.Height) (*clienttypes.QueryConsensusStateResponse, error)
- func (pr *Prover) QueryClientStateWithProof(_ int64) (*clienttypes.QueryClientStateResponse, error)
- func (pr *Prover) QueryConnectionWithProof(_ int64) (*conntypes.QueryConnectionResponse, error)
- func (pr *Prover) QueryLatestHeader() (out core.HeaderI, err error)
- func (pr *Prover) QueryPacketAcknowledgementCommitmentWithProof(_ int64, seq uint64) (ackRes *chantypes.QueryPacketAcknowledgementResponse, err error)
- func (pr *Prover) QueryPacketCommitmentWithProof(_ int64, seq uint64) (comRes *chantypes.QueryPacketCommitmentResponse, err error)
- func (pr *Prover) SetRelayInfo(_ *core.PathEnd, _ *core.ProvableChain, _ *core.PathEnd) error
- func (pr *Prover) SetupForRelay(ctx context.Context) error
- func (*Prover) SetupHeader(dst core.LightClientIBCQueryierI, baseSrcHeader core.HeaderI) (core.HeaderI, error)
- func (pr *Prover) UpdateLightWithHeader() (header core.HeaderI, provableHeight int64, queryableHeight int64, err error)
- type ProverConfig
- func (c ProverConfig) Build(chain core.ChainI) (core.ProverI, error)
- func (*ProverConfig) Descriptor() ([]byte, []int)
- func (m *ProverConfig) Marshal() (dAtA []byte, err error)
- func (m *ProverConfig) MarshalTo(dAtA []byte) (int, error)
- func (m *ProverConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ProverConfig) ProtoMessage()
- func (m *ProverConfig) Reset()
- func (m *ProverConfig) Size() (n int)
- func (m *ProverConfig) String() string
- func (m *ProverConfig) Unmarshal(dAtA []byte) error
- func (m *ProverConfig) XXX_DiscardUnknown()
- func (m *ProverConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ProverConfig) XXX_Merge(src proto.Message)
- func (m *ProverConfig) XXX_Size() int
- func (m *ProverConfig) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func RegisterInterfaces ¶
func RegisterInterfaces(registry codectypes.InterfaceRegistry)
RegisterInterfaces register the module interfaces to protobuf Any.
Types ¶
type Chain ¶
type Chain struct {
// contains filtered or unexported fields
}
func NewChain ¶
func NewChain(config ChainConfig) *Chain
func (*Chain) Codec ¶
func (c *Chain) Codec() codec.ProtoCodecMarshaler
func (*Chain) Config ¶
func (c *Chain) Config() ChainConfig
func (*Chain) GetAddress ¶
func (c *Chain) GetAddress() (sdk.AccAddress, error)
GetAddress returns the sdk.AccAddress associated with the configred key
func (*Chain) GetLatestHeight ¶
QueryLatestHeight queries the chain for the latest height and returns it
func (*Chain) GetSerializedIdentity ¶
func (c *Chain) GetSerializedIdentity(label string) (*msppb.SerializedIdentity, error)
func (*Chain) PopulateWallet ¶
func (*Chain) Query ¶
func (c *Chain) Query(req app.RequestQuery) (*app.ResponseQuery, error)
func (*Chain) QueryBalance ¶
QueryBalance returns the amount of coins in the relayer account
func (*Chain) QueryChannel ¶
func (c *Chain) QueryChannel(height int64) (chanRes *chantypes.QueryChannelResponse, err error)
QueryChannel returns the channel associated with a channelID
func (*Chain) QueryClientConsensusState ¶
func (c *Chain) QueryClientConsensusState(_ int64, dstClientConsHeight ibcexported.Height) (*clienttypes.QueryConsensusStateResponse, error)
func (*Chain) QueryClientState ¶
func (c *Chain) QueryClientState(_ int64) (*clienttypes.QueryClientStateResponse, error)
QueryClientState retrevies the latest consensus state for a client in state at a given height
func (*Chain) QueryConnection ¶
func (c *Chain) QueryConnection(_ int64) (*conntypes.QueryConnectionResponse, error)
QueryConnection returns the remote end of a given connection
func (*Chain) QueryCurrentSequence ¶
func (c *Chain) QueryCurrentSequence() (*commitment.Sequence, error)
QueryCurrentSequence returns the current sequence for IBC chaincode
func (*Chain) QueryDenomTraces ¶
func (c *Chain) QueryDenomTraces(offset, limit uint64, height int64) (*transfertypes.QueryDenomTracesResponse, error)
QueryDenomTraces returns all the denom traces from a given chain
func (*Chain) QueryPacket ¶
func (*Chain) QueryPacketAcknowledgement ¶
func (*Chain) QueryPacketAcknowledgementCommitment ¶
func (*Chain) QueryPacketAcknowledgementCommitments ¶
func (*Chain) QueryPacketCommitment ¶
func (*Chain) QueryPacketCommitments ¶
func (*Chain) QueryUnrecievedAcknowledgements ¶
func (*Chain) QueryUnrecievedPackets ¶
func (*Chain) RegisterMsgEventListener ¶
func (c *Chain) RegisterMsgEventListener(listener core.MsgEventListener)
RegisterMsgEventListener registers a given EventListener to the chain
func (*Chain) SetRelayInfo ¶
SetRelayInfo sets source's path and counterparty's info to the chain
type ChainConfig ¶
type ChainConfig struct { ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"` WalletLabel string `protobuf:"bytes,2,opt,name=wallet_label,json=walletLabel,proto3" json:"wallet_label,omitempty"` ConnectionProfilePath string `` /* 126-byte string literal not displayed */ Channel string `protobuf:"bytes,4,opt,name=channel,proto3" json:"channel,omitempty"` ChaincodeId string `protobuf:"bytes,5,opt,name=chaincode_id,json=chaincodeId,proto3" json:"chaincode_id,omitempty"` }
func (*ChainConfig) Descriptor ¶
func (*ChainConfig) Descriptor() ([]byte, []int)
func (*ChainConfig) Marshal ¶
func (m *ChainConfig) Marshal() (dAtA []byte, err error)
func (*ChainConfig) MarshalToSizedBuffer ¶
func (m *ChainConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ChainConfig) ProtoMessage ¶
func (*ChainConfig) ProtoMessage()
func (*ChainConfig) Reset ¶
func (m *ChainConfig) Reset()
func (*ChainConfig) Size ¶
func (m *ChainConfig) Size() (n int)
func (*ChainConfig) String ¶
func (m *ChainConfig) String() string
func (*ChainConfig) Unmarshal ¶
func (m *ChainConfig) Unmarshal(dAtA []byte) error
func (*ChainConfig) XXX_DiscardUnknown ¶
func (m *ChainConfig) XXX_DiscardUnknown()
func (*ChainConfig) XXX_Marshal ¶
func (m *ChainConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ChainConfig) XXX_Merge ¶
func (m *ChainConfig) XXX_Merge(src proto.Message)
func (*ChainConfig) XXX_Size ¶
func (m *ChainConfig) XXX_Size() int
func (*ChainConfig) XXX_Unmarshal ¶
func (m *ChainConfig) XXX_Unmarshal(b []byte) error
type FabricGateway ¶
type FabricGateway struct { ConfigProvider core.ConfigProvider `yaml:"-" json:"-"` Wallet *gateway.Wallet `yaml:"-" json:"-"` Gateway *gateway.Gateway `yaml:"-" json:"-"` Network *gateway.Network `yaml:"-" json:"-"` Contract *gateway.Contract `yaml:"-" json:"-"` }
func (*FabricGateway) PopulateWallet ¶
func (gw *FabricGateway) PopulateWallet(walletPath, mspID, certPath, privateKeyPath string) error
type Prover ¶
type Prover struct {
// contains filtered or unexported fields
}
func NewProver ¶
func NewProver(chain *Chain, config ProverConfig) *Prover
func (*Prover) CreateMsgCreateClient ¶
func (pr *Prover) CreateMsgCreateClient(clientID string, dstHeader core.HeaderI, signer sdk.AccAddress) (*clienttypes.MsgCreateClient, error)
CreateMsgCreateClient creates a CreateClientMsg to this chain
func (*Prover) GetLatestLightHeight ¶
GetLatestLightHeight uses the CLI utilities to pull the latest height from a given chain Fabric prover doesn't support "chain" height
func (*Prover) GetLocalMspConfigs ¶
get MSP Configs for Chain.IBCPolicies
func (*Prover) QueryChannelWithProof ¶
func (pr *Prover) QueryChannelWithProof(_ int64) (chanRes *chantypes.QueryChannelResponse, err error)
QueryChannelWithProof returns the Channel and its proof
func (*Prover) QueryClientConsensusStateWithProof ¶
func (pr *Prover) QueryClientConsensusStateWithProof(_ int64, dstClientConsHeight ibcexported.Height) (*clienttypes.QueryConsensusStateResponse, error)
QueryClientConsensusState returns the ClientConsensusState and its proof
func (*Prover) QueryClientStateWithProof ¶
func (pr *Prover) QueryClientStateWithProof(_ int64) (*clienttypes.QueryClientStateResponse, error)
QueryClientStateWithProof returns the ClientState and its proof
func (*Prover) QueryConnectionWithProof ¶
func (pr *Prover) QueryConnectionWithProof(_ int64) (*conntypes.QueryConnectionResponse, error)
QueryConnectionWithProof returns the Connection and its proof
func (*Prover) QueryLatestHeader ¶
QueryLatestHeader returns the latest header from the chain
func (*Prover) QueryPacketAcknowledgementCommitmentWithProof ¶
func (pr *Prover) QueryPacketAcknowledgementCommitmentWithProof(_ int64, seq uint64) (ackRes *chantypes.QueryPacketAcknowledgementResponse, err error)
QueryPacketAcknowledgementCommitmentWithProof returns the packet acknowledgement commitment and its proof
func (*Prover) QueryPacketCommitmentWithProof ¶
func (pr *Prover) QueryPacketCommitmentWithProof(_ int64, seq uint64) (comRes *chantypes.QueryPacketCommitmentResponse, err error)
QueryPacketCommitmentWithProof returns the packet commitment and its proof
func (*Prover) SetRelayInfo ¶
SetRelayInfo sets source's path and counterparty's info to the chain
func (*Prover) SetupHeader ¶
func (*Prover) SetupHeader(dst core.LightClientIBCQueryierI, baseSrcHeader core.HeaderI) (core.HeaderI, error)
SetupHeader creates a new header based on a given header
type ProverConfig ¶
type ProverConfig struct { IbcPolicies []string `protobuf:"bytes,1,rep,name=ibc_policies,json=ibcPolicies,proto3" json:"ibc_policies,omitempty"` EndorsementPolicies []string `protobuf:"bytes,2,rep,name=endorsement_policies,json=endorsementPolicies,proto3" json:"endorsement_policies,omitempty"` MspConfigPaths []string `protobuf:"bytes,3,rep,name=msp_config_paths,json=mspConfigPaths,proto3" json:"msp_config_paths,omitempty"` }
func (*ProverConfig) Descriptor ¶
func (*ProverConfig) Descriptor() ([]byte, []int)
func (*ProverConfig) Marshal ¶
func (m *ProverConfig) Marshal() (dAtA []byte, err error)
func (*ProverConfig) MarshalToSizedBuffer ¶
func (m *ProverConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ProverConfig) ProtoMessage ¶
func (*ProverConfig) ProtoMessage()
func (*ProverConfig) Reset ¶
func (m *ProverConfig) Reset()
func (*ProverConfig) Size ¶
func (m *ProverConfig) Size() (n int)
func (*ProverConfig) String ¶
func (m *ProverConfig) String() string
func (*ProverConfig) Unmarshal ¶
func (m *ProverConfig) Unmarshal(dAtA []byte) error
func (*ProverConfig) XXX_DiscardUnknown ¶
func (m *ProverConfig) XXX_DiscardUnknown()
func (*ProverConfig) XXX_Marshal ¶
func (m *ProverConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ProverConfig) XXX_Merge ¶
func (m *ProverConfig) XXX_Merge(src proto.Message)
func (*ProverConfig) XXX_Size ¶
func (m *ProverConfig) XXX_Size() int
func (*ProverConfig) XXX_Unmarshal ¶
func (m *ProverConfig) XXX_Unmarshal(b []byte) error