Update autogenerated bindings to latest LDK 0.0.123-bindings
[ldk-c-bindings] / lightning-c-bindings / src / lightning / util / ser.rs
index 6b5c46cf187f4d1da5a22d771b49c5093754b326..1235f5cd08206750603fbcb608cc3348c00a0731 100644 (file)
@@ -262,6 +262,11 @@ pub extern "C" fn Hostname_len(this_arg: &crate::lightning::util::ser::Hostname)
        ret
 }
 
+#[no_mangle]
+/// Get the string representation of a Hostname object
+pub extern "C" fn Hostname_to_str(o: &crate::lightning::util::ser::Hostname) -> Str {
+       alloc::format!("{}", o.get_native_ref()).into()
+}
 #[no_mangle]
 /// Serialize the Hostname object into a byte array which can be read by Hostname_read
 pub extern "C" fn Hostname_write(obj: &crate::lightning::util::ser::Hostname) -> crate::c_types::derived::CVec_u8Z {
@@ -391,6 +396,14 @@ pub extern "C" fn TransactionU16LenLimited_into_transaction(mut this_arg: crate:
        crate::c_types::Transaction::from_bitcoin(&ret)
 }
 
+/// Returns a reference to the contained `Transaction`
+#[must_use]
+#[no_mangle]
+pub extern "C" fn TransactionU16LenLimited_as_transaction(this_arg: &crate::lightning::util::ser::TransactionU16LenLimited) -> crate::c_types::Transaction {
+       let mut ret = unsafe { &*ObjOps::untweak_ptr(this_arg.inner) }.as_transaction();
+       crate::c_types::Transaction::from_bitcoin(ret)
+}
+
 #[no_mangle]
 /// Serialize the TransactionU16LenLimited object into a byte array which can be read by TransactionU16LenLimited_read
 pub extern "C" fn TransactionU16LenLimited_write(obj: &crate::lightning::util::ser::TransactionU16LenLimited) -> crate::c_types::derived::CVec_u8Z {