bpwallet/
lib.rs

1// Modern, minimalistic & standard-compliant cold wallet library.
2//
3// SPDX-License-Identifier: Apache-2.0
4//
5// Written in 2020-2024 by
6//     Dr Maxim Orlovsky <orlovsky@lnp-bp.org>
7//
8// Copyright (C) 2020-2024 LNP/BP Standards Association. All rights reserved.
9// Copyright (C) 2020-2024 Dr Maxim Orlovsky. All rights reserved.
10//
11// Licensed under the Apache License, Version 2.0 (the "License");
12// you may not use this file except in compliance with the License.
13// You may obtain a copy of the License at
14//
15//     http://www.apache.org/licenses/LICENSE-2.0
16//
17// Unless required by applicable law or agreed to in writing, software
18// distributed under the License is distributed on an "AS IS" BASIS,
19// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20// See the License for the specific language governing permissions and
21// limitations under the License.
22
23#[macro_use]
24extern crate amplify;
25#[cfg(feature = "serde")]
26extern crate serde_crate as serde;
27#[macro_use]
28#[cfg(feature = "clap")]
29extern crate clap;
30#[macro_use]
31#[cfg(feature = "log")]
32extern crate log;
33
34pub mod indexers;
35mod util;
36mod data;
37mod rows;
38mod wallet;
39mod layer2;
40pub mod coinselect;
41#[cfg(feature = "cli")]
42pub mod cli;
43#[cfg(feature = "signers")]
44pub mod hot;
45mod bip43;
46#[cfg(feature = "fs")]
47pub mod fs;
48
49pub use bip43::{Bip43, DerivationStandard, ParseBip43Error};
50pub use bpstd::*;
51pub use data::{
52    BlockHeight, BlockInfo, MiningInfo, Party, TxCredit, TxDebit, TxStatus, WalletAddr, WalletTx,
53    WalletUtxo,
54};
55#[cfg(feature = "hot")]
56pub use hot::{HotArgs, HotCommand};
57#[cfg(feature = "signers")]
58pub use hot::{Seed, SeedType};
59pub use indexers::Indexer;
60#[cfg(any(feature = "electrum", feature = "esplora", feature = "mempool"))]
61pub use indexers::{AnyIndexer, AnyIndexerError};
62pub use layer2::{
63    Layer2, Layer2Cache, Layer2Coin, Layer2Data, Layer2Descriptor, Layer2Empty, Layer2Tx, NoLayer2,
64};
65pub use rows::{CoinRow, Counterparty, OpType, TxRow};
66pub use util::MayError;
67pub use wallet::{Wallet, WalletCache, WalletData, WalletDescr};