Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContentReader ¶
ContentReader is responsible for fetching content based on it's CID.
type ContentStorage ¶
type ContentStorage interface {
ContentReader
ContentWriter
}
ContentStorage allows its user to access content based on CID.
type ContentWriter ¶
ContentWriter writes given content with assigned CID
type MessageReader ¶
type MessageReader interface {
Read(ctx context.Context, cid cid.Cid) (ProtoUnmarshallable, error)
}
MessageReader lets user access message based on CID address
type MessageStorage ¶
type MessageStorage interface {
MessageReader
MessageWriter
}
MessageStorage is responsible for accessing the messages based on CID
type MessageWriter ¶
MessageWriter persists message with CID accessor
type ProtoMessageStorage ¶
type ProtoMessageStorage struct {
// contains filtered or unexported fields
}
func NewProtoMessageStorage ¶
func NewProtoMessageStorage(contentStorage ContentStorage) *ProtoMessageStorage
func (*ProtoMessageStorage) Read ¶
func (p *ProtoMessageStorage) Read(ctx context.Context, cid cid.Cid) (ProtoUnmarshallable, error)
type ProtoUnmarshallable ¶
ProtoUnmarshallable can be used to deserialize message data to proto structure
Click to show internal directories.
Click to hide internal directories.