···498 }
499 {
500 checksum := rustCall(func(_uniffiStatus *C.RustCallStatus) C.uint16_t {
000000000501 return C.uniffi_iroh_streamplace_checksum_method_node_db()
502 })
503 if checksum != 39096 {
···15681569// Iroh-streamplace node that can send, forward or receive stream segments.
1570type NodeInterface interface {
001571 // Get a handle to the db to watch for changes locally or globally.
1572 Db() *Db
1573 // Join peers by their node tickets.
···1682 }
16831684 return res, err
000000000000000000000000000000001685}
16861687// Get a handle to the db to watch for changes locally or globally.
···498 }
499 {
500 checksum := rustCall(func(_uniffiStatus *C.RustCallStatus) C.uint16_t {
501+ return C.uniffi_iroh_streamplace_checksum_method_node_add_tickets()
502+ })
503+ if checksum != 8701 {
504+ // If this happens try cleaning and rebuilding your project
505+ panic("iroh_streamplace: uniffi_iroh_streamplace_checksum_method_node_add_tickets: UniFFI API checksum mismatch")
506+ }
507+ }
508+ {
509+ checksum := rustCall(func(_uniffiStatus *C.RustCallStatus) C.uint16_t {
510 return C.uniffi_iroh_streamplace_checksum_method_node_db()
511 })
512 if checksum != 39096 {
···15771578// Iroh-streamplace node that can send, forward or receive stream segments.
1579type NodeInterface interface {
1580+ // Add tickets for remote peers
1581+ AddTickets(peers []string) error
1582 // Get a handle to the db to watch for changes locally or globally.
1583 Db() *Db
1584 // Join peers by their node tickets.
···1693 }
16941695 return res, err
1696+}
1697+1698+// Add tickets for remote peers
1699+func (_self *Node) AddTickets(peers []string) error {
1700+ _pointer := _self.ffiObject.incrementPointer("*Node")
1701+ defer _self.ffiObject.decrementPointer()
1702+ _, err := uniffiRustCallAsync[JoinPeersError](
1703+ FfiConverterJoinPeersErrorINSTANCE,
1704+ // completeFn
1705+ func(handle C.uint64_t, status *C.RustCallStatus) struct{} {
1706+ C.ffi_iroh_streamplace_rust_future_complete_void(handle, status)
1707+ return struct{}{}
1708+ },
1709+ // liftFn
1710+ func(_ struct{}) struct{} { return struct{}{} },
1711+ C.uniffi_iroh_streamplace_fn_method_node_add_tickets(
1712+ _pointer, FfiConverterSequenceStringINSTANCE.Lower(peers)),
1713+ // pollFn
1714+ func(handle C.uint64_t, continuation C.UniffiRustFutureContinuationCallback, data C.uint64_t) {
1715+ C.ffi_iroh_streamplace_rust_future_poll_void(handle, continuation, data)
1716+ },
1717+ // freeFn
1718+ func(handle C.uint64_t) {
1719+ C.ffi_iroh_streamplace_rust_future_free_void(handle)
1720+ },
1721+ )
1722+1723+ if err == nil {
1724+ return nil
1725+ }
1726+1727+ return err
1728}
17291730// Get a handle to the db to watch for changes locally or globally.