feat: upload latest android source changes

This commit is contained in:
sue
2026-03-03 22:16:30 +08:00
parent c0a7109816
commit 0bf4f72141
56 changed files with 14949 additions and 2152 deletions

View File

@@ -0,0 +1,38 @@
package com.hikoncont.util.adaptation
import com.hikoncont.util.DeviceDetector.DeviceBrand
import com.hikoncont.util.DeviceDetector.KeepAlivePolicy
/**
* Device runtime fingerprint used by adaptation strategies.
*/
data class DeviceRuntimeInfo(
val brand: DeviceBrand,
val sdkInt: Int,
val brandRaw: String,
val manufacturerRaw: String,
val modelRaw: String,
val deviceRaw: String,
val productRaw: String
)
/**
* Strategy interface for per-device adaptation.
*
* Keep this interface focused and stable so new ROM/model behavior can be
* plugged in by adding a strategy class instead of editing many call sites.
*/
interface DeviceAdaptationStrategy {
val id: String
val priority: Int
fun matches(info: DeviceRuntimeInfo): Boolean
fun keepAlivePolicy(info: DeviceRuntimeInfo): KeepAlivePolicy
}
data class StrategyResolution(
val strategyId: String,
val keepAlivePolicy: KeepAlivePolicy
)