Skip to content

Commit 603ae5b

Browse files
committed
update to latest v3 version
1 parent fd50405 commit 603ae5b

File tree

1 file changed

+54
-0
lines changed

1 file changed

+54
-0
lines changed

library/src/main/java/xmtpv3.kt

+54
Original file line numberDiff line numberDiff line change
@@ -413,6 +413,8 @@ internal interface _UniFFILib : Library {
413413
): RustBuffer.ByValue
414414
fun uniffi_xmtpv3_fn_method_ffigroup_id(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
415415
): RustBuffer.ByValue
416+
fun uniffi_xmtpv3_fn_method_ffigroup_is_active(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
417+
): Byte
416418
fun uniffi_xmtpv3_fn_method_ffigroup_list_members(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
417419
): RustBuffer.ByValue
418420
fun uniffi_xmtpv3_fn_method_ffigroup_remove_members(`ptr`: Pointer,`accountAddresses`: RustBuffer.ByValue,
@@ -427,6 +429,8 @@ internal interface _UniFFILib : Library {
427429
): Unit
428430
fun uniffi_xmtpv3_fn_method_ffistreamcloser_end(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
429431
): Unit
432+
fun uniffi_xmtpv3_fn_method_ffistreamcloser_is_closed(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
433+
): Byte
430434
fun uniffi_xmtpv3_fn_free_ffiv2apiclient(`ptr`: Pointer,_uniffi_out_err: RustCallStatus,
431435
): Unit
432436
fun uniffi_xmtpv3_fn_method_ffiv2apiclient_batch_query(`ptr`: Pointer,`req`: RustBuffer.ByValue,
@@ -475,6 +479,8 @@ internal interface _UniFFILib : Library {
475479
): RustBuffer.ByValue
476480
fun uniffi_xmtpv3_fn_func_generate_private_preferences_topic_identifier(`privateKey`: RustBuffer.ByValue,_uniffi_out_err: RustCallStatus,
477481
): RustBuffer.ByValue
482+
fun uniffi_xmtpv3_fn_func_get_version_info(_uniffi_out_err: RustCallStatus,
483+
): RustBuffer.ByValue
478484
fun uniffi_xmtpv3_fn_func_keccak256(`input`: RustBuffer.ByValue,_uniffi_out_err: RustCallStatus,
479485
): RustBuffer.ByValue
480486
fun uniffi_xmtpv3_fn_func_public_key_from_private_key_k256(`privateKeyBytes`: RustBuffer.ByValue,_uniffi_out_err: RustCallStatus,
@@ -615,6 +621,8 @@ internal interface _UniFFILib : Library {
615621
): Short
616622
fun uniffi_xmtpv3_checksum_func_generate_private_preferences_topic_identifier(
617623
): Short
624+
fun uniffi_xmtpv3_checksum_func_get_version_info(
625+
): Short
618626
fun uniffi_xmtpv3_checksum_func_keccak256(
619627
): Short
620628
fun uniffi_xmtpv3_checksum_func_public_key_from_private_key_k256(
@@ -649,6 +657,8 @@ internal interface _UniFFILib : Library {
649657
): Short
650658
fun uniffi_xmtpv3_checksum_method_ffigroup_id(
651659
): Short
660+
fun uniffi_xmtpv3_checksum_method_ffigroup_is_active(
661+
): Short
652662
fun uniffi_xmtpv3_checksum_method_ffigroup_list_members(
653663
): Short
654664
fun uniffi_xmtpv3_checksum_method_ffigroup_remove_members(
@@ -661,6 +671,8 @@ internal interface _UniFFILib : Library {
661671
): Short
662672
fun uniffi_xmtpv3_checksum_method_ffistreamcloser_end(
663673
): Short
674+
fun uniffi_xmtpv3_checksum_method_ffistreamcloser_is_closed(
675+
): Short
664676
fun uniffi_xmtpv3_checksum_method_ffiv2apiclient_batch_query(
665677
): Short
666678
fun uniffi_xmtpv3_checksum_method_ffiv2apiclient_publish(
@@ -726,6 +738,9 @@ private fun uniffiCheckApiChecksums(lib: _UniFFILib) {
726738
if (lib.uniffi_xmtpv3_checksum_func_generate_private_preferences_topic_identifier() != 5952.toShort()) {
727739
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
728740
}
741+
if (lib.uniffi_xmtpv3_checksum_func_get_version_info() != 3533.toShort()) {
742+
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
743+
}
729744
if (lib.uniffi_xmtpv3_checksum_func_keccak256() != 17749.toShort()) {
730745
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
731746
}
@@ -777,6 +792,9 @@ private fun uniffiCheckApiChecksums(lib: _UniFFILib) {
777792
if (lib.uniffi_xmtpv3_checksum_method_ffigroup_id() != 35243.toShort()) {
778793
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
779794
}
795+
if (lib.uniffi_xmtpv3_checksum_method_ffigroup_is_active() != 27808.toShort()) {
796+
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
797+
}
780798
if (lib.uniffi_xmtpv3_checksum_method_ffigroup_list_members() != 15786.toShort()) {
781799
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
782800
}
@@ -795,6 +813,9 @@ private fun uniffiCheckApiChecksums(lib: _UniFFILib) {
795813
if (lib.uniffi_xmtpv3_checksum_method_ffistreamcloser_end() != 47211.toShort()) {
796814
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
797815
}
816+
if (lib.uniffi_xmtpv3_checksum_method_ffistreamcloser_is_closed() != 37884.toShort()) {
817+
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
818+
}
798819
if (lib.uniffi_xmtpv3_checksum_method_ffiv2apiclient_batch_query() != 10812.toShort()) {
799820
throw RuntimeException("UniFFI API checksum mismatch: try cleaning and rebuilding your project")
800821
}
@@ -1379,6 +1400,7 @@ public interface FfiGroupInterface {
13791400
fun `createdAtNs`(): Long@Throws(GenericException::class)
13801401
fun `findMessages`(`opts`: FfiListMessagesOptions): List<FfiMessage>
13811402
fun `id`(): ByteArray@Throws(GenericException::class)
1403+
fun `isActive`(): Boolean@Throws(GenericException::class)
13821404
fun `listMembers`(): List<FfiGroupMember>@Throws(GenericException::class)
13831405
suspend fun `removeMembers`(`accountAddresses`: List<String>)@Throws(GenericException::class)
13841406
suspend fun `send`(`contentBytes`: ByteArray)@Throws(GenericException::class)
@@ -1461,6 +1483,18 @@ class FfiGroup(
14611483
}
14621484

14631485

1486+
@Throws(GenericException::class)override fun `isActive`(): Boolean =
1487+
callWithPointer {
1488+
rustCallWithError(GenericException) { _status ->
1489+
_UniFFILib.INSTANCE.uniffi_xmtpv3_fn_method_ffigroup_is_active(it,
1490+
1491+
_status)
1492+
}
1493+
}.let {
1494+
FfiConverterBoolean.lift(it)
1495+
}
1496+
1497+
14641498
@Throws(GenericException::class)override fun `listMembers`(): List<FfiGroupMember> =
14651499
callWithPointer {
14661500
rustCallWithError(GenericException) { _status ->
@@ -1590,6 +1624,7 @@ public object FfiConverterTypeFfiGroup: FfiConverter<FfiGroup, Pointer> {
15901624
public interface FfiStreamCloserInterface {
15911625

15921626
fun `end`()
1627+
fun `isClosed`(): Boolean
15931628
companion object
15941629
}
15951630

@@ -1621,6 +1656,17 @@ class FfiStreamCloser(
16211656
}
16221657

16231658

1659+
override fun `isClosed`(): Boolean =
1660+
callWithPointer {
1661+
rustCall() { _status ->
1662+
_UniFFILib.INSTANCE.uniffi_xmtpv3_fn_method_ffistreamcloser_is_closed(it,
1663+
1664+
_status)
1665+
}
1666+
}.let {
1667+
FfiConverterBoolean.lift(it)
1668+
}
1669+
16241670

16251671

16261672

@@ -3511,6 +3557,14 @@ fun `generatePrivatePreferencesTopicIdentifier`(`privateKey`: ByteArray): String
35113557
}
35123558

35133559

3560+
fun `getVersionInfo`(): String {
3561+
return FfiConverterString.lift(
3562+
rustCall() { _status ->
3563+
_UniFFILib.INSTANCE.uniffi_xmtpv3_fn_func_get_version_info(_status)
3564+
})
3565+
}
3566+
3567+
35143568
fun `keccak256`(`input`: ByteArray): ByteArray {
35153569
return FfiConverterByteArray.lift(
35163570
rustCall() { _status ->

0 commit comments

Comments
 (0)