mirror of
https://github.com/AthanorLabs/atomic-swap.git
synced 2026-04-22 03:00:02 -04:00
18 lines
450 B
Go
18 lines
450 B
Go
// Copyright 2023 The AthanorLabs/atomic-swap Authors
|
|
// SPDX-License-Identifier: LGPL-3.0-only
|
|
|
|
package offers
|
|
|
|
import (
|
|
"github.com/athanorlabs/atomic-swap/common/types"
|
|
)
|
|
|
|
// Database contains the db functions used by the offer manager.
|
|
type Database interface {
|
|
PutOffer(offer *types.Offer) error
|
|
DeleteOffer(id types.Hash) error
|
|
GetOffer(id types.Hash) (*types.Offer, error)
|
|
GetAllOffers() ([]*types.Offer, error)
|
|
ClearAllOffers() error
|
|
}
|