services

package
v2.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Koinos_GetAccountHistory_FullMethodName            = "/koinos.services.koinos/get_account_history"
	Koinos_GetBlocksById_FullMethodName                = "/koinos.services.koinos/get_blocks_by_id"
	Koinos_GetBlocksByHeight_FullMethodName            = "/koinos.services.koinos/get_blocks_by_height"
	Koinos_GetHighestBlock_FullMethodName              = "/koinos.services.koinos/get_highest_block"
	Koinos_SubmitBlock_FullMethodName                  = "/koinos.services.koinos/submit_block"
	Koinos_SubmitTransaction_FullMethodName            = "/koinos.services.koinos/submit_transaction"
	Koinos_GetHeadInfo_FullMethodName                  = "/koinos.services.koinos/get_head_info"
	Koinos_GetChainId_FullMethodName                   = "/koinos.services.koinos/get_chain_id"
	Koinos_GetForkHeads_FullMethodName                 = "/koinos.services.koinos/get_fork_heads"
	Koinos_ReadContract_FullMethodName                 = "/koinos.services.koinos/read_contract"
	Koinos_GetAccountNonce_FullMethodName              = "/koinos.services.koinos/get_account_nonce"
	Koinos_GetAccountRc_FullMethodName                 = "/koinos.services.koinos/get_account_rc"
	Koinos_GetResourceLimits_FullMethodName            = "/koinos.services.koinos/get_resource_limits"
	Koinos_InvokeSystemCall_FullMethodName             = "/koinos.services.koinos/invoke_system_call"
	Koinos_GetContractMeta_FullMethodName              = "/koinos.services.koinos/get_contract_meta"
	Koinos_GetPendingTransactions_FullMethodName       = "/koinos.services.koinos/get_pending_transactions"
	Koinos_CheckPendingAccountResources_FullMethodName = "/koinos.services.koinos/check_pending_account_resources"
	Koinos_GetGossipStatus_FullMethodName              = "/koinos.services.koinos/get_gossip_status"
	Koinos_GetTransactionsById_FullMethodName          = "/koinos.services.koinos/get_transactions_by_id"
)

Variables

View Source
var File_koinos_rpc_services_proto protoreflect.FileDescriptor
View Source
var Koinos_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "koinos.services.koinos",
	HandlerType: (*KoinosServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "get_account_history",
			Handler:    _Koinos_GetAccountHistory_Handler,
		},
		{
			MethodName: "get_blocks_by_id",
			Handler:    _Koinos_GetBlocksById_Handler,
		},
		{
			MethodName: "get_blocks_by_height",
			Handler:    _Koinos_GetBlocksByHeight_Handler,
		},
		{
			MethodName: "get_highest_block",
			Handler:    _Koinos_GetHighestBlock_Handler,
		},
		{
			MethodName: "submit_block",
			Handler:    _Koinos_SubmitBlock_Handler,
		},
		{
			MethodName: "submit_transaction",
			Handler:    _Koinos_SubmitTransaction_Handler,
		},
		{
			MethodName: "get_head_info",
			Handler:    _Koinos_GetHeadInfo_Handler,
		},
		{
			MethodName: "get_chain_id",
			Handler:    _Koinos_GetChainId_Handler,
		},
		{
			MethodName: "get_fork_heads",
			Handler:    _Koinos_GetForkHeads_Handler,
		},
		{
			MethodName: "read_contract",
			Handler:    _Koinos_ReadContract_Handler,
		},
		{
			MethodName: "get_account_nonce",
			Handler:    _Koinos_GetAccountNonce_Handler,
		},
		{
			MethodName: "get_account_rc",
			Handler:    _Koinos_GetAccountRc_Handler,
		},
		{
			MethodName: "get_resource_limits",
			Handler:    _Koinos_GetResourceLimits_Handler,
		},
		{
			MethodName: "invoke_system_call",
			Handler:    _Koinos_InvokeSystemCall_Handler,
		},
		{
			MethodName: "get_contract_meta",
			Handler:    _Koinos_GetContractMeta_Handler,
		},
		{
			MethodName: "get_pending_transactions",
			Handler:    _Koinos_GetPendingTransactions_Handler,
		},
		{
			MethodName: "check_pending_account_resources",
			Handler:    _Koinos_CheckPendingAccountResources_Handler,
		},
		{
			MethodName: "get_gossip_status",
			Handler:    _Koinos_GetGossipStatus_Handler,
		},
		{
			MethodName: "get_transactions_by_id",
			Handler:    _Koinos_GetTransactionsById_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "koinos/rpc/services.proto",
}

Koinos_ServiceDesc is the grpc.ServiceDesc for Koinos service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterKoinosServer

func RegisterKoinosServer(s grpc.ServiceRegistrar, srv KoinosServer)

Types

type KoinosClient

type KoinosClient interface {
	// Account History
	GetAccountHistory(ctx context.Context, in *account_history.GetAccountHistoryRequest, opts ...grpc.CallOption) (*account_history.GetAccountHistoryResponse, error)
	// Block Store
	GetBlocksById(ctx context.Context, in *block_store.GetBlocksByIdRequest, opts ...grpc.CallOption) (*block_store.GetBlocksByIdResponse, error)
	GetBlocksByHeight(ctx context.Context, in *block_store.GetBlocksByHeightRequest, opts ...grpc.CallOption) (*block_store.GetBlocksByHeightResponse, error)
	GetHighestBlock(ctx context.Context, in *block_store.GetHighestBlockRequest, opts ...grpc.CallOption) (*block_store.GetHighestBlockResponse, error)
	// Chain
	SubmitBlock(ctx context.Context, in *chain.SubmitBlockRequest, opts ...grpc.CallOption) (*chain.SubmitBlockResponse, error)
	SubmitTransaction(ctx context.Context, in *chain.SubmitTransactionRequest, opts ...grpc.CallOption) (*chain.SubmitTransactionResponse, error)
	GetHeadInfo(ctx context.Context, in *chain.GetHeadInfoRequest, opts ...grpc.CallOption) (*chain.GetHeadInfoResponse, error)
	GetChainId(ctx context.Context, in *chain.GetChainIdRequest, opts ...grpc.CallOption) (*chain.GetChainIdResponse, error)
	GetForkHeads(ctx context.Context, in *chain.GetForkHeadsRequest, opts ...grpc.CallOption) (*chain.GetForkHeadsResponse, error)
	ReadContract(ctx context.Context, in *chain.ReadContractRequest, opts ...grpc.CallOption) (*chain.ReadContractResponse, error)
	GetAccountNonce(ctx context.Context, in *chain.GetAccountNonceRequest, opts ...grpc.CallOption) (*chain.GetAccountNonceResponse, error)
	GetAccountRc(ctx context.Context, in *chain.GetAccountRcRequest, opts ...grpc.CallOption) (*chain.GetAccountRcResponse, error)
	GetResourceLimits(ctx context.Context, in *chain.GetResourceLimitsRequest, opts ...grpc.CallOption) (*chain.GetResourceLimitsResponse, error)
	InvokeSystemCall(ctx context.Context, in *chain.InvokeSystemCallRequest, opts ...grpc.CallOption) (*chain.InvokeSystemCallResponse, error)
	// Contract Meta Store
	GetContractMeta(ctx context.Context, in *contract_meta_store.GetContractMetaRequest, opts ...grpc.CallOption) (*contract_meta_store.GetContractMetaResponse, error)
	// Mempool
	GetPendingTransactions(ctx context.Context, in *mempool.GetPendingTransactionsRequest, opts ...grpc.CallOption) (*mempool.GetPendingTransactionsResponse, error)
	CheckPendingAccountResources(ctx context.Context, in *mempool.CheckPendingAccountResourcesRequest, opts ...grpc.CallOption) (*mempool.CheckPendingAccountResourcesResponse, error)
	// P2P
	GetGossipStatus(ctx context.Context, in *p2p.GetGossipStatusRequest, opts ...grpc.CallOption) (*p2p.GetGossipStatusResponse, error)
	// Transaction Store
	GetTransactionsById(ctx context.Context, in *transaction_store.GetTransactionsByIdRequest, opts ...grpc.CallOption) (*transaction_store.GetTransactionsByIdResponse, error)
}

KoinosClient is the client API for Koinos service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewKoinosClient

func NewKoinosClient(cc grpc.ClientConnInterface) KoinosClient

type KoinosServer

type KoinosServer interface {
	// Account History
	GetAccountHistory(context.Context, *account_history.GetAccountHistoryRequest) (*account_history.GetAccountHistoryResponse, error)
	// Block Store
	GetBlocksById(context.Context, *block_store.GetBlocksByIdRequest) (*block_store.GetBlocksByIdResponse, error)
	GetBlocksByHeight(context.Context, *block_store.GetBlocksByHeightRequest) (*block_store.GetBlocksByHeightResponse, error)
	GetHighestBlock(context.Context, *block_store.GetHighestBlockRequest) (*block_store.GetHighestBlockResponse, error)
	// Chain
	SubmitBlock(context.Context, *chain.SubmitBlockRequest) (*chain.SubmitBlockResponse, error)
	SubmitTransaction(context.Context, *chain.SubmitTransactionRequest) (*chain.SubmitTransactionResponse, error)
	GetHeadInfo(context.Context, *chain.GetHeadInfoRequest) (*chain.GetHeadInfoResponse, error)
	GetChainId(context.Context, *chain.GetChainIdRequest) (*chain.GetChainIdResponse, error)
	GetForkHeads(context.Context, *chain.GetForkHeadsRequest) (*chain.GetForkHeadsResponse, error)
	ReadContract(context.Context, *chain.ReadContractRequest) (*chain.ReadContractResponse, error)
	GetAccountNonce(context.Context, *chain.GetAccountNonceRequest) (*chain.GetAccountNonceResponse, error)
	GetAccountRc(context.Context, *chain.GetAccountRcRequest) (*chain.GetAccountRcResponse, error)
	GetResourceLimits(context.Context, *chain.GetResourceLimitsRequest) (*chain.GetResourceLimitsResponse, error)
	InvokeSystemCall(context.Context, *chain.InvokeSystemCallRequest) (*chain.InvokeSystemCallResponse, error)
	// Contract Meta Store
	GetContractMeta(context.Context, *contract_meta_store.GetContractMetaRequest) (*contract_meta_store.GetContractMetaResponse, error)
	// Mempool
	GetPendingTransactions(context.Context, *mempool.GetPendingTransactionsRequest) (*mempool.GetPendingTransactionsResponse, error)
	CheckPendingAccountResources(context.Context, *mempool.CheckPendingAccountResourcesRequest) (*mempool.CheckPendingAccountResourcesResponse, error)
	// P2P
	GetGossipStatus(context.Context, *p2p.GetGossipStatusRequest) (*p2p.GetGossipStatusResponse, error)
	// Transaction Store
	GetTransactionsById(context.Context, *transaction_store.GetTransactionsByIdRequest) (*transaction_store.GetTransactionsByIdResponse, error)
	// contains filtered or unexported methods
}

KoinosServer is the server API for Koinos service. All implementations must embed UnimplementedKoinosServer for forward compatibility

type UnimplementedKoinosServer

type UnimplementedKoinosServer struct {
}

UnimplementedKoinosServer must be embedded to have forward compatible implementations.

func (UnimplementedKoinosServer) GetChainId

func (UnimplementedKoinosServer) GetHeadInfo

func (UnimplementedKoinosServer) SubmitBlock

type UnsafeKoinosServer

type UnsafeKoinosServer interface {
	// contains filtered or unexported methods
}

UnsafeKoinosServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KoinosServer will result in compilation errors.

Jump to

Keyboard shortcuts

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