@@ -2886,7 +2886,7 @@ public protocol RoomProtocol {
2886
2886
func sendReadReceipt(eventId: String) throws
2887
2887
func sendReply(msg: RoomMessageEventContentWithoutRelation, inReplyToEventId: String, txnId: String?) throws
2888
2888
func sendVideo(url: String, thumbnailUrl: String, videoInfo: VideoInfo, progressWatcher: ProgressWatcher?) -> SendAttachmentJoinHandle
2889
- func setName(name: String? ) throws
2889
+ func setName(name: String) throws
2890
2890
func setTopic(topic: String) throws
2891
2891
func subscribeToBackPaginationStatus(listener: BackPaginationStatusListener) throws -> TaskHandle
2892
2892
func subscribeToRoomInfoUpdates(listener: RoomInfoListener) -> TaskHandle
@@ -3856,11 +3856,11 @@ public class Room: RoomProtocol {
3856
3856
)
3857
3857
}
3858
3858
3859
- public func setName(name: String? ) throws {
3859
+ public func setName(name: String) throws {
3860
3860
try
3861
3861
rustCallWithError(FfiConverterTypeClientError.lift) {
3862
3862
uniffi_matrix_sdk_ffi_fn_method_room_set_name(self.pointer,
3863
- FfiConverterOptionString .lower(name),$0
3863
+ FfiConverterString .lower(name),$0
3864
3864
)
3865
3865
}
3866
3866
}
@@ -6723,13 +6723,17 @@ public struct AudioMessageContent {
6723
6723
public var body: String
6724
6724
public var source: MediaSource
6725
6725
public var info: AudioInfo?
6726
+ public var audio: UnstableAudioDetailsContent?
6727
+ public var voice: UnstableVoiceContent?
6726
6728
6727
6729
// Default memberwise initializers are never public by default, so we
6728
6730
// declare one manually.
6729
- public init(body: String, source: MediaSource, info: AudioInfo?) {
6731
+ public init(body: String, source: MediaSource, info: AudioInfo?, audio: UnstableAudioDetailsContent?, voice: UnstableVoiceContent? ) {
6730
6732
self.body = body
6731
6733
self.source = source
6732
6734
self.info = info
6735
+ self.audio = audio
6736
+ self.voice = voice
6733
6737
}
6734
6738
}
6735
6739
@@ -6740,14 +6744,18 @@ public struct FfiConverterTypeAudioMessageContent: FfiConverterRustBuffer {
6740
6744
return try AudioMessageContent(
6741
6745
body: FfiConverterString.read(from: &buf),
6742
6746
source: FfiConverterTypeMediaSource.read(from: &buf),
6743
- info: FfiConverterOptionTypeAudioInfo.read(from: &buf)
6747
+ info: FfiConverterOptionTypeAudioInfo.read(from: &buf),
6748
+ audio: FfiConverterOptionTypeUnstableAudioDetailsContent.read(from: &buf),
6749
+ voice: FfiConverterOptionTypeUnstableVoiceContent.read(from: &buf)
6744
6750
)
6745
6751
}
6746
6752
6747
6753
public static func write(_ value: AudioMessageContent, into buf: inout [UInt8]) {
6748
6754
FfiConverterString.write(value.body, into: &buf)
6749
6755
FfiConverterTypeMediaSource.write(value.source, into: &buf)
6750
6756
FfiConverterOptionTypeAudioInfo.write(value.info, into: &buf)
6757
+ FfiConverterOptionTypeUnstableAudioDetailsContent.write(value.audio, into: &buf)
6758
+ FfiConverterOptionTypeUnstableVoiceContent.write(value.voice, into: &buf)
6751
6759
}
6752
6760
}
6753
6761
@@ -9128,6 +9136,100 @@ public func FfiConverterTypeTransmissionProgress_lower(_ value: TransmissionProg
9128
9136
}
9129
9137
9130
9138
9139
+ public struct UnstableAudioDetailsContent {
9140
+ public var duration: TimeInterval
9141
+ public var waveform: [UInt16]
9142
+
9143
+ // Default memberwise initializers are never public by default, so we
9144
+ // declare one manually.
9145
+ public init(duration: TimeInterval, waveform: [UInt16]) {
9146
+ self.duration = duration
9147
+ self.waveform = waveform
9148
+ }
9149
+ }
9150
+
9151
+
9152
+ extension UnstableAudioDetailsContent: Equatable, Hashable {
9153
+ public static func ==(lhs: UnstableAudioDetailsContent, rhs: UnstableAudioDetailsContent) -> Bool {
9154
+ if lhs.duration != rhs.duration {
9155
+ return false
9156
+ }
9157
+ if lhs.waveform != rhs.waveform {
9158
+ return false
9159
+ }
9160
+ return true
9161
+ }
9162
+
9163
+ public func hash(into hasher: inout Hasher) {
9164
+ hasher.combine(duration)
9165
+ hasher.combine(waveform)
9166
+ }
9167
+ }
9168
+
9169
+
9170
+ public struct FfiConverterTypeUnstableAudioDetailsContent: FfiConverterRustBuffer {
9171
+ public static func read(from buf: inout (data: Data, offset: Data.Index)) throws -> UnstableAudioDetailsContent {
9172
+ return try UnstableAudioDetailsContent(
9173
+ duration: FfiConverterDuration.read(from: &buf),
9174
+ waveform: FfiConverterSequenceUInt16.read(from: &buf)
9175
+ )
9176
+ }
9177
+
9178
+ public static func write(_ value: UnstableAudioDetailsContent, into buf: inout [UInt8]) {
9179
+ FfiConverterDuration.write(value.duration, into: &buf)
9180
+ FfiConverterSequenceUInt16.write(value.waveform, into: &buf)
9181
+ }
9182
+ }
9183
+
9184
+
9185
+ public func FfiConverterTypeUnstableAudioDetailsContent_lift(_ buf: RustBuffer) throws -> UnstableAudioDetailsContent {
9186
+ return try FfiConverterTypeUnstableAudioDetailsContent.lift(buf)
9187
+ }
9188
+
9189
+ public func FfiConverterTypeUnstableAudioDetailsContent_lower(_ value: UnstableAudioDetailsContent) -> RustBuffer {
9190
+ return FfiConverterTypeUnstableAudioDetailsContent.lower(value)
9191
+ }
9192
+
9193
+
9194
+ public struct UnstableVoiceContent {
9195
+
9196
+ // Default memberwise initializers are never public by default, so we
9197
+ // declare one manually.
9198
+ public init() {
9199
+ }
9200
+ }
9201
+
9202
+
9203
+ extension UnstableVoiceContent: Equatable, Hashable {
9204
+ public static func ==(lhs: UnstableVoiceContent, rhs: UnstableVoiceContent) -> Bool {
9205
+ return true
9206
+ }
9207
+
9208
+ public func hash(into hasher: inout Hasher) {
9209
+ }
9210
+ }
9211
+
9212
+
9213
+ public struct FfiConverterTypeUnstableVoiceContent: FfiConverterRustBuffer {
9214
+ public static func read(from buf: inout (data: Data, offset: Data.Index)) throws -> UnstableVoiceContent {
9215
+ return try UnstableVoiceContent(
9216
+ )
9217
+ }
9218
+
9219
+ public static func write(_ value: UnstableVoiceContent, into buf: inout [UInt8]) {
9220
+ }
9221
+ }
9222
+
9223
+
9224
+ public func FfiConverterTypeUnstableVoiceContent_lift(_ buf: RustBuffer) throws -> UnstableVoiceContent {
9225
+ return try FfiConverterTypeUnstableVoiceContent.lift(buf)
9226
+ }
9227
+
9228
+ public func FfiConverterTypeUnstableVoiceContent_lower(_ value: UnstableVoiceContent) -> RustBuffer {
9229
+ return FfiConverterTypeUnstableVoiceContent.lower(value)
9230
+ }
9231
+
9232
+
9131
9233
public struct UserProfile {
9132
9234
public var userId: String
9133
9235
public var displayName: String?
@@ -15754,6 +15856,48 @@ fileprivate struct FfiConverterOptionTypeTracingFileConfiguration: FfiConverterR
15754
15856
}
15755
15857
}
15756
15858
15859
+ fileprivate struct FfiConverterOptionTypeUnstableAudioDetailsContent: FfiConverterRustBuffer {
15860
+ typealias SwiftType = UnstableAudioDetailsContent?
15861
+
15862
+ public static func write(_ value: SwiftType, into buf: inout [UInt8]) {
15863
+ guard let value = value else {
15864
+ writeInt(&buf, Int8(0))
15865
+ return
15866
+ }
15867
+ writeInt(&buf, Int8(1))
15868
+ FfiConverterTypeUnstableAudioDetailsContent.write(value, into: &buf)
15869
+ }
15870
+
15871
+ public static func read(from buf: inout (data: Data, offset: Data.Index)) throws -> SwiftType {
15872
+ switch try readInt(&buf) as Int8 {
15873
+ case 0: return nil
15874
+ case 1: return try FfiConverterTypeUnstableAudioDetailsContent.read(from: &buf)
15875
+ default: throw UniffiInternalError.unexpectedOptionalTag
15876
+ }
15877
+ }
15878
+ }
15879
+
15880
+ fileprivate struct FfiConverterOptionTypeUnstableVoiceContent: FfiConverterRustBuffer {
15881
+ typealias SwiftType = UnstableVoiceContent?
15882
+
15883
+ public static func write(_ value: SwiftType, into buf: inout [UInt8]) {
15884
+ guard let value = value else {
15885
+ writeInt(&buf, Int8(0))
15886
+ return
15887
+ }
15888
+ writeInt(&buf, Int8(1))
15889
+ FfiConverterTypeUnstableVoiceContent.write(value, into: &buf)
15890
+ }
15891
+
15892
+ public static func read(from buf: inout (data: Data, offset: Data.Index)) throws -> SwiftType {
15893
+ switch try readInt(&buf) as Int8 {
15894
+ case 0: return nil
15895
+ case 1: return try FfiConverterTypeUnstableVoiceContent.read(from: &buf)
15896
+ default: throw UniffiInternalError.unexpectedOptionalTag
15897
+ }
15898
+ }
15899
+ }
15900
+
15757
15901
fileprivate struct FfiConverterOptionTypeVideoInfo: FfiConverterRustBuffer {
15758
15902
typealias SwiftType = VideoInfo?
15759
15903
@@ -16175,6 +16319,28 @@ fileprivate struct FfiConverterSequenceUInt8: FfiConverterRustBuffer {
16175
16319
}
16176
16320
}
16177
16321
16322
+ fileprivate struct FfiConverterSequenceUInt16: FfiConverterRustBuffer {
16323
+ typealias SwiftType = [UInt16]
16324
+
16325
+ public static func write(_ value: [UInt16], into buf: inout [UInt8]) {
16326
+ let len = Int32(value.count)
16327
+ writeInt(&buf, len)
16328
+ for item in value {
16329
+ FfiConverterUInt16.write(item, into: &buf)
16330
+ }
16331
+ }
16332
+
16333
+ public static func read(from buf: inout (data: Data, offset: Data.Index)) throws -> [UInt16] {
16334
+ let len: Int32 = try readInt(&buf)
16335
+ var seq = [UInt16]()
16336
+ seq.reserveCapacity(Int(len))
16337
+ for _ in 0 ..< len {
16338
+ seq.append(try FfiConverterUInt16.read(from: &buf))
16339
+ }
16340
+ return seq
16341
+ }
16342
+ }
16343
+
16178
16344
fileprivate struct FfiConverterSequenceString: FfiConverterRustBuffer {
16179
16345
typealias SwiftType = [String]
16180
16346
@@ -18726,7 +18892,7 @@ private var initializationResult: InitializationResult {
18726
18892
if (uniffi_matrix_sdk_ffi_checksum_method_room_send_video() != 38775) {
18727
18893
return InitializationResult.apiChecksumMismatch
18728
18894
}
18729
- if (uniffi_matrix_sdk_ffi_checksum_method_room_set_name() != 39725 ) {
18895
+ if (uniffi_matrix_sdk_ffi_checksum_method_room_set_name() != 56429 ) {
18730
18896
return InitializationResult.apiChecksumMismatch
18731
18897
}
18732
18898
if (uniffi_matrix_sdk_ffi_checksum_method_room_set_topic() != 55348) {
0 commit comments