Documentation
¶
Index ¶
- func BytesToNamespaceV0(bytes []byte) (share.Namespace, error)
- func HexToNamespaceV0(namespaceId string) (share.Namespace, error)
- type BlobStore
- type CelestiaDA
- func (c *CelestiaDA) Cfg() DAConfig
- func (c *CelestiaDA) GetBlobs(ctx context.Context, height uint64) ([]*blob.Blob, error)
- func (c *CelestiaDA) GetHeader(ctx context.Context, height uint64) (*header.ExtendedHeader, error)
- func (c *CelestiaDA) Has(ctx context.Context, height uint64, commitment []byte) (bool, error)
- func (c *CelestiaDA) LatestHeight(ctx context.Context) (uint64, error)
- func (c *CelestiaDA) Namespace() share.Namespace
- func (c *CelestiaDA) Read(ctx context.Context, height uint64, commitment []byte) ([]byte, error)
- func (c *CelestiaDA) Store(ctx context.Context, message []byte) ([]byte, uint64, error)
- func (c *CelestiaDA) StoreBatch(ctx context.Context, messages [][]byte) ([][]byte, uint64, error)
- func (c *CelestiaDA) SubscribeToNewHeaders(ctx context.Context) (<-chan CompactHeader, error)
- type CompactHeader
- type DAConfig
- type NoopDA
- func (d *NoopDA) Cfg() DAConfig
- func (d *NoopDA) GetBlobs(_ context.Context, height uint64) ([]*blob.Blob, error)
- func (d *NoopDA) GetHeader(_ context.Context, height uint64) (*header.ExtendedHeader, error)
- func (d *NoopDA) Has(_ context.Context, height uint64, _ []byte) (bool, error)
- func (d *NoopDA) LatestHeight(_ context.Context) (uint64, error)
- func (d *NoopDA) Namespace() share.Namespace
- func (d *NoopDA) Read(_ context.Context, height uint64, _ []byte) ([]byte, error)
- func (d *NoopDA) Store(_ context.Context, msg []byte) ([]byte, uint64, error)
- func (d *NoopDA) StoreBatch(_ context.Context, msgs [][]byte) ([][]byte, uint64, error)
- func (d *NoopDA) SubscribeToNewHeaders(_ context.Context) (<-chan CompactHeader, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BlobStore ¶
type BlobStore interface {
Store(ctx context.Context, msg []byte) (commitment []byte, height uint64, err error)
StoreBatch(ctx context.Context, msgs [][]byte) (commitments [][]byte, height uint64, err error)
Has(ctx context.Context, height uint64, commitment []byte) (bool, error)
Read(ctx context.Context, height uint64, commitment []byte) ([]byte, error)
GetBlobs(ctx context.Context, height uint64) ([]*blob.Blob, error)
LatestHeight(ctx context.Context) (uint64, error)
GetHeader(ctx context.Context, height uint64) (*header.ExtendedHeader, error)
SubscribeToNewHeaders(ctx context.Context) (<-chan CompactHeader, error)
Namespace() share.Namespace
Cfg() DAConfig
}
type CelestiaDA ¶
type CelestiaDA struct {
// contains filtered or unexported fields
}
Client for interacting with Celestia
func NewCelestiaDA ¶
func NewCelestiaDA(cfg DAConfig) (*CelestiaDA, error)
Create a new Celestia DA client
func (*CelestiaDA) Cfg ¶
func (c *CelestiaDA) Cfg() DAConfig
func (*CelestiaDA) GetHeader ¶
func (c *CelestiaDA) GetHeader(ctx context.Context, height uint64) (*header.ExtendedHeader, error)
func (*CelestiaDA) LatestHeight ¶
func (c *CelestiaDA) LatestHeight(ctx context.Context) (uint64, error)
func (*CelestiaDA) Namespace ¶
func (c *CelestiaDA) Namespace() share.Namespace
func (*CelestiaDA) StoreBatch ¶
func (*CelestiaDA) SubscribeToNewHeaders ¶
func (c *CelestiaDA) SubscribeToNewHeaders(ctx context.Context) (<-chan CompactHeader, error)
type CompactHeader ¶
type NoopDA ¶
type NoopDA struct {
// contains filtered or unexported fields
}
func (*NoopDA) StoreBatch ¶
func (*NoopDA) SubscribeToNewHeaders ¶
func (d *NoopDA) SubscribeToNewHeaders(_ context.Context) (<-chan CompactHeader, error)
Click to show internal directories.
Click to hide internal directories.