Skip to content

Commit 271f8e3

Browse files
committed
Bump to version 25.03.31 (matrix-rust-sdk/main fb04539418158cf8f975b750a33f506867941de3)
1 parent 0da89f2 commit 271f8e3

File tree

2 files changed

+111
-19
lines changed

2 files changed

+111
-19
lines changed

Package.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// swift-tools-version:5.9
22
// The swift-tools-version declares the minimum version of Swift required to build this package.
33
import PackageDescription
4-
let checksum = "81c8622717dc675a49e784ecd81d1719cb98218769f1a20d5c65def437e3d06e"
5-
let version = "25.03.24"
4+
let checksum = "7f106d37a6ed587e3b87d09596d20202f4dba09b2ba015707ca03dde65e1c4d0"
5+
let version = "25.03.31"
66
let url = "https://github.com/element-hq/matrix-rust-components-swift/releases/download/\(version)/MatrixSDKFFI.xcframework.zip"
77
let package = Package(
88
name: "MatrixRustSDK",

Sources/MatrixRustSDK/matrix_sdk_ffi.swift

Lines changed: 109 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5607,7 +5607,7 @@ public protocol RoomProtocol : AnyObject {
56075607
*/
56085608
func stopLiveLocationShare() async throws
56095609

5610-
func subscribeToIdentityStatusChanges(listener: IdentityStatusChangeListener) -> TaskHandle
5610+
func subscribeToIdentityStatusChanges(listener: IdentityStatusChangeListener) async throws -> TaskHandle
56115611

56125612
/**
56135613
* Subscribes to requests to join this room (knock member events), using a
@@ -7078,12 +7078,21 @@ open func stopLiveLocationShare()async throws {
70787078
)
70797079
}
70807080

7081-
open func subscribeToIdentityStatusChanges(listener: IdentityStatusChangeListener) -> TaskHandle {
7082-
return try! FfiConverterTypeTaskHandle.lift(try! rustCall() {
7083-
uniffi_matrix_sdk_ffi_fn_method_room_subscribe_to_identity_status_changes(self.uniffiClonePointer(),
7084-
FfiConverterCallbackInterfaceIdentityStatusChangeListener.lower(listener),$0
7085-
)
7086-
})
7081+
open func subscribeToIdentityStatusChanges(listener: IdentityStatusChangeListener)async throws -> TaskHandle {
7082+
return
7083+
try await uniffiRustCallAsync(
7084+
rustFutureFunc: {
7085+
uniffi_matrix_sdk_ffi_fn_method_room_subscribe_to_identity_status_changes(
7086+
self.uniffiClonePointer(),
7087+
FfiConverterCallbackInterfaceIdentityStatusChangeListener.lower(listener)
7088+
)
7089+
},
7090+
pollFunc: ffi_matrix_sdk_ffi_rust_future_poll_pointer,
7091+
completeFunc: ffi_matrix_sdk_ffi_rust_future_complete_pointer,
7092+
freeFunc: ffi_matrix_sdk_ffi_rust_future_free_pointer,
7093+
liftFunc: FfiConverterTypeTaskHandle.lift,
7094+
errorHandler: FfiConverterTypeClientError.lift
7095+
)
70877096
}
70887097

70897098
/**
@@ -10507,7 +10516,7 @@ public protocol TimelineProtocol : AnyObject {
1050710516
*/
1050810517
func edit(eventOrTransactionId: EventOrTransactionId, newContent: EditedContent) async throws
1050910518

10510-
func endPoll(pollStartEventId: String, text: String) throws
10519+
func endPoll(pollStartEventId: String, text: String) async throws
1051110520

1051210521
func fetchDetailsForEvent(eventId: String) async throws
1051310522

@@ -10602,8 +10611,31 @@ public protocol TimelineProtocol : AnyObject {
1060210611

1060310612
func sendReadReceipt(receiptType: ReceiptType, eventId: String) async throws
1060410613

10614+
/**
10615+
* Send a reply.
10616+
*
10617+
* If the replied to event has a thread relation, it is forwarded on the
10618+
* reply so that clients that support threads can render the reply
10619+
* inside the thread.
10620+
*/
1060510621
func sendReply(msg: RoomMessageEventContentWithoutRelation, eventId: String) async throws
1060610622

10623+
/**
10624+
* Send a message on a thread.
10625+
*
10626+
* If the replied to event does not have a thread relation, it becomes the
10627+
* root of a new thread.
10628+
*
10629+
* # Arguments
10630+
*
10631+
* * `msg` - Message content to send
10632+
*
10633+
* * `event_id` - ID of the event to reply to
10634+
*
10635+
* * `is_reply` - Whether the message is a reply on a thread
10636+
*/
10637+
func sendThreadReply(msg: RoomMessageEventContentWithoutRelation, eventId: String, isReply: Bool) async throws
10638+
1060710639
func sendVideo(params: UploadParameters, thumbnailPath: String?, videoInfo: VideoInfo, progressWatcher: ProgressWatcher?) throws -> SendAttachmentJoinHandle
1060810640

1060910641
func sendVoiceMessage(params: UploadParameters, audioInfo: AudioInfo, waveform: [UInt16], progressWatcher: ProgressWatcher?) throws -> SendAttachmentJoinHandle
@@ -10747,12 +10779,21 @@ open func edit(eventOrTransactionId: EventOrTransactionId, newContent: EditedCon
1074710779
)
1074810780
}
1074910781

10750-
open func endPoll(pollStartEventId: String, text: String)throws {try rustCallWithError(FfiConverterTypeClientError.lift) {
10751-
uniffi_matrix_sdk_ffi_fn_method_timeline_end_poll(self.uniffiClonePointer(),
10752-
FfiConverterString.lower(pollStartEventId),
10753-
FfiConverterString.lower(text),$0
10754-
)
10755-
}
10782+
open func endPoll(pollStartEventId: String, text: String)async throws {
10783+
return
10784+
try await uniffiRustCallAsync(
10785+
rustFutureFunc: {
10786+
uniffi_matrix_sdk_ffi_fn_method_timeline_end_poll(
10787+
self.uniffiClonePointer(),
10788+
FfiConverterString.lower(pollStartEventId),FfiConverterString.lower(text)
10789+
)
10790+
},
10791+
pollFunc: ffi_matrix_sdk_ffi_rust_future_poll_void,
10792+
completeFunc: ffi_matrix_sdk_ffi_rust_future_complete_void,
10793+
freeFunc: ffi_matrix_sdk_ffi_rust_future_free_void,
10794+
liftFunc: { $0 },
10795+
errorHandler: FfiConverterTypeClientError.lift
10796+
)
1075610797
}
1075710798

1075810799
open func fetchDetailsForEvent(eventId: String)async throws {
@@ -11075,6 +11116,13 @@ open func sendReadReceipt(receiptType: ReceiptType, eventId: String)async throws
1107511116
)
1107611117
}
1107711118

11119+
/**
11120+
* Send a reply.
11121+
*
11122+
* If the replied to event has a thread relation, it is forwarded on the
11123+
* reply so that clients that support threads can render the reply
11124+
* inside the thread.
11125+
*/
1107811126
open func sendReply(msg: RoomMessageEventContentWithoutRelation, eventId: String)async throws {
1107911127
return
1108011128
try await uniffiRustCallAsync(
@@ -11092,6 +11140,37 @@ open func sendReply(msg: RoomMessageEventContentWithoutRelation, eventId: String
1109211140
)
1109311141
}
1109411142

11143+
/**
11144+
* Send a message on a thread.
11145+
*
11146+
* If the replied to event does not have a thread relation, it becomes the
11147+
* root of a new thread.
11148+
*
11149+
* # Arguments
11150+
*
11151+
* * `msg` - Message content to send
11152+
*
11153+
* * `event_id` - ID of the event to reply to
11154+
*
11155+
* * `is_reply` - Whether the message is a reply on a thread
11156+
*/
11157+
open func sendThreadReply(msg: RoomMessageEventContentWithoutRelation, eventId: String, isReply: Bool)async throws {
11158+
return
11159+
try await uniffiRustCallAsync(
11160+
rustFutureFunc: {
11161+
uniffi_matrix_sdk_ffi_fn_method_timeline_send_thread_reply(
11162+
self.uniffiClonePointer(),
11163+
FfiConverterTypeRoomMessageEventContentWithoutRelation.lower(msg),FfiConverterString.lower(eventId),FfiConverterBool.lower(isReply)
11164+
)
11165+
},
11166+
pollFunc: ffi_matrix_sdk_ffi_rust_future_poll_void,
11167+
completeFunc: ffi_matrix_sdk_ffi_rust_future_complete_void,
11168+
freeFunc: ffi_matrix_sdk_ffi_rust_future_free_void,
11169+
liftFunc: { $0 },
11170+
errorHandler: FfiConverterTypeClientError.lift
11171+
)
11172+
}
11173+
1109511174
open func sendVideo(params: UploadParameters, thumbnailPath: String?, videoInfo: VideoInfo, progressWatcher: ProgressWatcher?)throws -> SendAttachmentJoinHandle {
1109611175
return try FfiConverterTypeSendAttachmentJoinHandle.lift(try rustCallWithError(FfiConverterTypeRoomError.lift) {
1109711176
uniffi_matrix_sdk_ffi_fn_method_timeline_send_video(self.uniffiClonePointer(),
@@ -27813,6 +27892,10 @@ public enum VirtualTimelineItem {
2781327892
* The user's own read marker.
2781427893
*/
2781527894
case readMarker
27895+
/**
27896+
* The timeline start, that is, the *oldest* event in time for that room.
27897+
*/
27898+
case timelineStart
2781627899
}
2781727900

2781827901

@@ -27828,6 +27911,8 @@ public struct FfiConverterTypeVirtualTimelineItem: FfiConverterRustBuffer {
2782827911

2782927912
case 2: return .readMarker
2783027913

27914+
case 3: return .timelineStart
27915+
2783127916
default: throw UniffiInternalError.unexpectedEnumCase
2783227917
}
2783327918
}
@@ -27844,6 +27929,10 @@ public struct FfiConverterTypeVirtualTimelineItem: FfiConverterRustBuffer {
2784427929
case .readMarker:
2784527930
writeInt(&buf, Int32(2))
2784627931

27932+
27933+
case .timelineStart:
27934+
writeInt(&buf, Int32(3))
27935+
2784727936
}
2784827937
}
2784927938
}
@@ -33862,7 +33951,7 @@ private var initializationResult: InitializationResult = {
3386233951
if (uniffi_matrix_sdk_ffi_checksum_method_room_stop_live_location_share() != 19983) {
3386333952
return InitializationResult.apiChecksumMismatch
3386433953
}
33865-
if (uniffi_matrix_sdk_ffi_checksum_method_room_subscribe_to_identity_status_changes() != 14290) {
33954+
if (uniffi_matrix_sdk_ffi_checksum_method_room_subscribe_to_identity_status_changes() != 8526) {
3386633955
return InitializationResult.apiChecksumMismatch
3386733956
}
3386833957
if (uniffi_matrix_sdk_ffi_checksum_method_room_subscribe_to_knock_requests() != 30649) {
@@ -34132,7 +34221,7 @@ private var initializationResult: InitializationResult = {
3413234221
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_edit() != 42189) {
3413334222
return InitializationResult.apiChecksumMismatch
3413434223
}
34135-
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_end_poll() != 61329) {
34224+
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_end_poll() != 32659) {
3413634225
return InitializationResult.apiChecksumMismatch
3413734226
}
3413834227
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_fetch_details_for_event() != 54068) {
@@ -34186,7 +34275,10 @@ private var initializationResult: InitializationResult = {
3418634275
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_send_read_receipt() != 37532) {
3418734276
return InitializationResult.apiChecksumMismatch
3418834277
}
34189-
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_send_reply() != 64747) {
34278+
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_send_reply() != 11149) {
34279+
return InitializationResult.apiChecksumMismatch
34280+
}
34281+
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_send_thread_reply() != 62758) {
3419034282
return InitializationResult.apiChecksumMismatch
3419134283
}
3419234284
if (uniffi_matrix_sdk_ffi_checksum_method_timeline_send_video() != 1445) {

0 commit comments

Comments
 (0)