Documentation ¶
Index ¶
- type StateManager
- type StateManagerSingle
- func (sm *StateManagerSingle) AddCosignature(_ context.Context, vk *[types.VerificationKeySize]byte, ...) error
- func (sm *StateManagerSingle) Cosigned(_ context.Context) (*types.CosignedTreeHead, error)
- func (sm *StateManagerSingle) Latest(ctx context.Context) (*types.SignedTreeHead, error)
- func (sm *StateManagerSingle) Run(ctx context.Context)
- func (sm *StateManagerSingle) ToSign(_ context.Context) (*types.SignedTreeHead, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StateManager ¶
type StateManager interface { Latest(context.Context) (*types.SignedTreeHead, error) ToSign(context.Context) (*types.SignedTreeHead, error) Cosigned(context.Context) (*types.CosignedTreeHead, error) AddCosignature(context.Context, *[types.VerificationKeySize]byte, *[types.SignatureSize]byte) error Run(context.Context) }
StateManager coordinates access to the log's tree heads and (co)signatures
type StateManagerSingle ¶
StateManagerSingle implements the StateManager interface. It is assumed that the log server is running on a single-instance machine. So, no coordination.
func NewStateManagerSingle ¶
func (*StateManagerSingle) AddCosignature ¶
func (sm *StateManagerSingle) AddCosignature(_ context.Context, vk *[types.VerificationKeySize]byte, sig *[types.SignatureSize]byte) error
func (*StateManagerSingle) Cosigned ¶
func (sm *StateManagerSingle) Cosigned(_ context.Context) (*types.CosignedTreeHead, error)
func (*StateManagerSingle) Latest ¶
func (sm *StateManagerSingle) Latest(ctx context.Context) (*types.SignedTreeHead, error)
func (*StateManagerSingle) Run ¶
func (sm *StateManagerSingle) Run(ctx context.Context)
func (*StateManagerSingle) ToSign ¶
func (sm *StateManagerSingle) ToSign(_ context.Context) (*types.SignedTreeHead, error)
Click to show internal directories.
Click to hide internal directories.