pub struct AndroidUpdateResponse {
pub has_update: bool,
pub version_name: Option<String>,
pub version_code: Option<i64>,
pub upgrade_type: Option<UpgradeType>,
pub min_version_code: Option<i64>,
pub download_url: Option<String>,
pub release_notes: Option<String>,
pub size_bytes: Option<i64>,
pub sha256: Option<String>,
}Expand description
RN Android 更新检查 GET /api/v1/updates/android/:app_slug 的响应体(扁平)。
与 Tauri 的 204-absence 不同:RN 统一 200,用 has_update boolean 区分。
has_update:false 时其余字段全部省略(尤其 download_url,避免 SDK 误下载)。
signature 不在此——RN 用 sha256 做传输完整性预校验,APK 真伪由 Android
安装器在安装时验 v2/v3 签名兜底(不加 minisign)。
Fields§
§has_update: bool§version_name: Option<String>§version_code: Option<i64>§upgrade_type: Option<UpgradeType>§min_version_code: Option<i64>强更下限(整数 versionCode);None = 无下限(upgrade_type=prompt)。
download_url: Option<String>§release_notes: Option<String>§size_bytes: Option<i64>§sha256: Option<String>Implementations§
Trait Implementations§
Source§impl Clone for AndroidUpdateResponse
impl Clone for AndroidUpdateResponse
Source§fn clone(&self) -> AndroidUpdateResponse
fn clone(&self) -> AndroidUpdateResponse
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ComposeSchema for AndroidUpdateResponse
impl ComposeSchema for AndroidUpdateResponse
Source§impl Debug for AndroidUpdateResponse
impl Debug for AndroidUpdateResponse
Source§impl<'de> Deserialize<'de> for AndroidUpdateResponse
impl<'de> Deserialize<'de> for AndroidUpdateResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for AndroidUpdateResponse
impl Serialize for AndroidUpdateResponse
Auto Trait Implementations§
impl Freeze for AndroidUpdateResponse
impl RefUnwindSafe for AndroidUpdateResponse
impl Send for AndroidUpdateResponse
impl Sync for AndroidUpdateResponse
impl Unpin for AndroidUpdateResponse
impl UnsafeUnpin for AndroidUpdateResponse
impl UnwindSafe for AndroidUpdateResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more