@@ -395,7 +395,7 @@ internal interface _UniFFILib : Library {
395
395
396
396
fun uniffi_xmtpv3_fn_free_fficonversations (`ptr`: Pointer ,_uniffi_out_err : RustCallStatus ,
397
397
): Unit
398
- fun uniffi_xmtpv3_fn_method_fficonversations_create_group (`ptr`: Pointer ,`accountAddresses`: RustBuffer .ByValue ,
398
+ fun uniffi_xmtpv3_fn_method_fficonversations_create_group (`ptr`: Pointer ,`accountAddresses`: RustBuffer .ByValue ,`permissions`: RustBuffer . ByValue ,
399
399
): Pointer
400
400
fun uniffi_xmtpv3_fn_method_fficonversations_list (`ptr`: Pointer ,`opts`: RustBuffer .ByValue ,
401
401
): Pointer
@@ -768,7 +768,7 @@ private fun uniffiCheckApiChecksums(lib: _UniFFILib) {
768
768
if (lib.uniffi_xmtpv3_checksum_func_verify_k256_sha256() != 31332 .toShort()) {
769
769
throw RuntimeException (" UniFFI API checksum mismatch: try cleaning and rebuilding your project" )
770
770
}
771
- if (lib.uniffi_xmtpv3_checksum_method_fficonversations_create_group() != 45500 .toShort()) {
771
+ if (lib.uniffi_xmtpv3_checksum_method_fficonversations_create_group() != 16460 .toShort()) {
772
772
throw RuntimeException (" UniFFI API checksum mismatch: try cleaning and rebuilding your project" )
773
773
}
774
774
if (lib.uniffi_xmtpv3_checksum_method_fficonversations_list() != 44067 .toShort()) {
@@ -1256,7 +1256,7 @@ abstract class FFIObject(
1256
1256
1257
1257
public interface FfiConversationsInterface {
1258
1258
@Throws(GenericException ::class )
1259
- suspend fun `createGroup` (`accountAddresses`: List <String >): FfiGroup @Throws (GenericException ::class)
1259
+ suspend fun `createGroup` (`accountAddresses`: List <String >, `permissions`: GroupPermissions ? ): FfiGroup @Throws (GenericException ::class)
1260
1260
suspend fun `list` (`opts`: FfiListConversationsOptions ): List <FfiGroup >@Throws (GenericException ::class)
1261
1261
suspend fun `stream` (`callback`: FfiConversationCallback ): FfiStreamCloser @Throws (GenericException ::class)
1262
1262
suspend fun `sync` ()
@@ -1284,12 +1284,12 @@ class FfiConversations(
1284
1284
1285
1285
@Throws(GenericException ::class )
1286
1286
@Suppress(" ASSIGNED_BUT_NEVER_ACCESSED_VARIABLE" )
1287
- override suspend fun `createGroup` (`accountAddresses`: List <String >) : FfiGroup {
1287
+ override suspend fun `createGroup` (`accountAddresses`: List <String >, `permissions`: GroupPermissions ? ) : FfiGroup {
1288
1288
return uniffiRustCallAsync(
1289
1289
callWithPointer { thisPtr ->
1290
1290
_UniFFILib .INSTANCE .uniffi_xmtpv3_fn_method_fficonversations_create_group(
1291
1291
thisPtr,
1292
- FfiConverterSequenceString .lower(`accountAddresses`),
1292
+ FfiConverterSequenceString .lower(`accountAddresses`),FfiConverterOptionalTypeGroupPermissions .lower(`permissions`),
1293
1293
)
1294
1294
},
1295
1295
{ future, continuation -> _UniFFILib .INSTANCE .ffi_xmtpv3_rust_future_poll_pointer(future, continuation) },
@@ -2613,6 +2613,30 @@ public object FfiConverterTypeGenericError : FfiConverterRustBuffer<GenericExcep
2613
2613
2614
2614
2615
2615
2616
+ enum class GroupPermissions {
2617
+ EVERYONE_IS_ADMIN ,GROUP_CREATOR_IS_ADMIN ;
2618
+ companion object
2619
+ }
2620
+
2621
+ public object FfiConverterTypeGroupPermissions: FfiConverterRustBuffer<GroupPermissions> {
2622
+ override fun read (buf : ByteBuffer ) = try {
2623
+ GroupPermissions .values()[buf.getInt() - 1 ]
2624
+ } catch (e: IndexOutOfBoundsException ) {
2625
+ throw RuntimeException (" invalid enum value, something is very wrong!!" , e)
2626
+ }
2627
+
2628
+ override fun allocationSize (value : GroupPermissions ) = 4
2629
+
2630
+ override fun write (value : GroupPermissions , buf : ByteBuffer ) {
2631
+ buf.putInt(value.ordinal + 1 )
2632
+ }
2633
+ }
2634
+
2635
+
2636
+
2637
+
2638
+
2639
+
2616
2640
enum class LegacyIdentitySource {
2617
2641
NONE ,STATIC ,NETWORK ,KEY_GENERATOR ;
2618
2642
companion object
@@ -3283,6 +3307,35 @@ public object FfiConverterOptionalTypeFfiPagingInfo: FfiConverterRustBuffer<FfiP
3283
3307
3284
3308
3285
3309
3310
+ public object FfiConverterOptionalTypeGroupPermissions: FfiConverterRustBuffer<GroupPermissions?> {
3311
+ override fun read (buf : ByteBuffer ): GroupPermissions ? {
3312
+ if (buf.get().toInt() == 0 ) {
3313
+ return null
3314
+ }
3315
+ return FfiConverterTypeGroupPermissions .read(buf)
3316
+ }
3317
+
3318
+ override fun allocationSize (value : GroupPermissions ? ): Int {
3319
+ if (value == null ) {
3320
+ return 1
3321
+ } else {
3322
+ return 1 + FfiConverterTypeGroupPermissions .allocationSize(value)
3323
+ }
3324
+ }
3325
+
3326
+ override fun write (value : GroupPermissions ? , buf : ByteBuffer ) {
3327
+ if (value == null ) {
3328
+ buf.put(0 )
3329
+ } else {
3330
+ buf.put(1 )
3331
+ FfiConverterTypeGroupPermissions .write(value, buf)
3332
+ }
3333
+ }
3334
+ }
3335
+
3336
+
3337
+
3338
+
3286
3339
public object FfiConverterSequenceBoolean: FfiConverterRustBuffer<List<Boolean>> {
3287
3340
override fun read (buf : ByteBuffer ): List <Boolean > {
3288
3341
val len = buf.getInt()
0 commit comments