From 3ce0e0004df2a3f138a5f1733b6fb7e13bdb728a Mon Sep 17 00:00:00 2001 From: shenjack-5600u <3695888@qq.com> Date: Sun, 6 Apr 2025 20:22:42 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=A5=E5=85=85=20room=20api?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ica-rs/src/py/class/ica.rs | 4 ++++ news/0-9.md | 2 ++ 2 files changed, 6 insertions(+) diff --git a/ica-rs/src/py/class/ica.rs b/ica-rs/src/py/class/ica.rs index 0f9d6fe..db67531 100644 --- a/ica-rs/src/py/class/ica.rs +++ b/ica-rs/src/py/class/ica.rs @@ -127,6 +127,10 @@ impl IcaRoomPy { pub fn get_room_name(&self) -> String { self.inner.room_name.clone() } #[getter] pub fn get_unread_count(&self) -> u64 { self.inner.unread_count } + #[getter] + pub fn get_priority(&self) -> u8 { self.inner.priority } + #[getter] + pub fn get_utime(&self) -> i64 { self.inner.utime } pub fn is_group(&self) -> bool { self.inner.room_id.is_room() } pub fn is_chat(&self) -> bool { self.inner.room_id.is_chat() } pub fn new_message_to(&self, content: String) -> SendMessagePy { diff --git a/news/0-9.md b/news/0-9.md index e2e0079..94697fe 100644 --- a/news/0-9.md +++ b/news/0-9.md @@ -18,6 +18,8 @@ - `room_name -> int` 群名 (String) - `unread_count -> int` 未读消息数 (u64) + - `priority -> int` 优先级 (u8) + - `utime -> int` 最后活跃时间 (unix sec * 1000) - `def new_message_to(self, content: str) -> IcaSendMessage` - 用于创建一条指向这个房间的消息