+ let tagged_hash = TaggedHash::new(SIGNATURE_TAG, &bytes);
+
+ Self { bytes, invoice_request, tagged_hash }
+ }
+
+ /// Signs the invoice request using the given function.
+ ///
+ /// This is not exported to bindings users as functions are not yet mapped.
+ pub fn sign<F, E>(mut self, sign: F) -> Result<InvoiceRequest, SignError<E>>
+ where
+ F: FnOnce(&Self) -> Result<Signature, E>
+ {