Skip to content

Commit

Permalink
feat: expose derivation_index method on wallet type
Browse files Browse the repository at this point in the history
  • Loading branch information
thunderbiscuit committed Aug 29, 2024
1 parent 34a33d8 commit 9d1a276
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bdk-ffi/src/bdk.udl
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,8 @@ interface Wallet {
[Name=load, Throws=LoadWithPersistError]
constructor(Descriptor descriptor, Descriptor change_descriptor, Connection connection);

u32? derivation_index(KeychainKind keychain);

AddressInfo reveal_next_address(KeychainKind keychain);

Network network();
Expand Down
4 changes: 4 additions & 0 deletions bdk-ffi/src/wallet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@ impl Wallet {
.map_err(CannotConnectError::from)
}

pub(crate) fn derivation_index(&self, keychain: KeychainKind) -> Option<u32> {
self.get_wallet().derivation_index(keychain)
}

pub fn network(&self) -> Network {
self.get_wallet().network()
}
Expand Down

0 comments on commit 9d1a276

Please sign in to comment.