Documentation ¶
Index ¶
- type Client
- func (c *Client) Get(peerChainID ids.ID, keys [][]byte) (values [][]byte, err error)
- func (c *Client) Indexed(peerChainID ids.ID, traits [][]byte, startTrait, startKey []byte, limit int) (values [][]byte, lastTrait, lastKey []byte, err error)
- func (c *Client) Put(peerChainID ids.ID, elems []*atomic.Element, batches ...database.Batch) error
- func (c *Client) Remove(peerChainID ids.ID, keys [][]byte, batches ...database.Batch) error
- type Server
- func (s *Server) Get(_ context.Context, req *gsharedmemoryproto.GetRequest) (*gsharedmemoryproto.GetResponse, error)
- func (s *Server) Indexed(_ context.Context, req *gsharedmemoryproto.IndexedRequest) (*gsharedmemoryproto.IndexedResponse, error)
- func (s *Server) Put(_ context.Context, req *gsharedmemoryproto.PutRequest) (*gsharedmemoryproto.PutResponse, error)
- func (s *Server) Remove(_ context.Context, req *gsharedmemoryproto.RemoveRequest) (*gsharedmemoryproto.RemoveResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an implementation of a messenger channel that talks over RPC.
func NewClient ¶
func NewClient(client gsharedmemoryproto.SharedMemoryClient) *Client
NewClient returns a shared memory instance connected to a shared memory instance
func (*Client) Indexed ¶
func (c *Client) Indexed( peerChainID ids.ID, traits [][]byte, startTrait, startKey []byte, limit int, ) ( values [][]byte, lastTrait, lastKey []byte, err error, )
Indexed ...
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is a messenger that is managed over RPC.
func NewServer ¶
func NewServer(sm atomic.SharedMemory, db database.Database) *Server
NewServer returns a vm instance connected to a remote vm instance
func (*Server) Get ¶
func (s *Server) Get( _ context.Context, req *gsharedmemoryproto.GetRequest, ) (*gsharedmemoryproto.GetResponse, error)
Get ...
func (*Server) Indexed ¶
func (s *Server) Indexed( _ context.Context, req *gsharedmemoryproto.IndexedRequest, ) (*gsharedmemoryproto.IndexedResponse, error)
Indexed ...
func (*Server) Put ¶
func (s *Server) Put( _ context.Context, req *gsharedmemoryproto.PutRequest, ) (*gsharedmemoryproto.PutResponse, error)
Put ...
func (*Server) Remove ¶
func (s *Server) Remove( _ context.Context, req *gsharedmemoryproto.RemoveRequest, ) (*gsharedmemoryproto.RemoveResponse, error)
Remove ...
Click to show internal directories.
Click to hide internal directories.