Documentation ¶
Index ¶
- func NewServer(impl types.ChainWriter, opts ...ServerOpt) pb.ChainWriterServer
- func RegisterChainWriterService(s *grpc.Server, chainWriter types.ChainWriter)
- func TxMetaFromProto(proto *pb.TransactionMeta) *types.TxMeta
- func TxMetaToProto(meta *types.TxMeta) *pb.TransactionMeta
- type Client
- func (c *Client) GetFeeComponents(ctx context.Context) (*types.ChainFeeComponents, error)
- func (c *Client) GetTransactionStatus(ctx context.Context, transactionID string) (types.TransactionStatus, error)
- func (c *Client) SubmitTransaction(ctx context.Context, contractName, method string, params any, ...) error
- type ClientOpt
- type Server
- func (s *Server) GetFeeComponents(ctx context.Context, _ *emptypb.Empty) (*pb.GetFeeComponentsReply, error)
- func (s *Server) GetTransactionStatus(ctx context.Context, req *pb.GetTransactionStatusRequest) (*pb.GetTransactionStatusReply, error)
- func (s *Server) SubmitTransaction(ctx context.Context, req *pb.SubmitTransactionRequest) (*emptypb.Empty, error)
- type ServerOpt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewServer ¶
func NewServer(impl types.ChainWriter, opts ...ServerOpt) pb.ChainWriterServer
func RegisterChainWriterService ¶
func RegisterChainWriterService(s *grpc.Server, chainWriter types.ChainWriter)
func TxMetaFromProto ¶
func TxMetaFromProto(proto *pb.TransactionMeta) *types.TxMeta
TxMetaFromProto converts a TxMeta from it's generated protobuf Go type to our internal Go type.
func TxMetaToProto ¶
func TxMetaToProto(meta *types.TxMeta) *pb.TransactionMeta
TxMetaToProto converts a TxMeta to it's generated protobuf Go type.
Types ¶
type Client ¶
type Client struct { *goplugin.ServiceClient // contains filtered or unexported fields }
func (*Client) GetFeeComponents ¶
func (*Client) GetTransactionStatus ¶
type ClientOpt ¶
type ClientOpt func(*Client)
func WithClientEncoding ¶
func WithClientEncoding(version chainreader.EncodingVersion) ClientOpt
type Server ¶
type Server struct { pb.UnimplementedChainWriterServer // contains filtered or unexported fields }
func (*Server) GetFeeComponents ¶
func (*Server) GetTransactionStatus ¶
func (s *Server) GetTransactionStatus(ctx context.Context, req *pb.GetTransactionStatusRequest) (*pb.GetTransactionStatusReply, error)
func (*Server) SubmitTransaction ¶
type ServerOpt ¶
type ServerOpt func(*Server)
func WithServerEncoding ¶
func WithServerEncoding(version chainreader.EncodingVersion) ServerOpt
Click to show internal directories.
Click to hide internal directories.