初始化
This commit is contained in:
@@ -0,0 +1,101 @@
|
||||
// ignore_for_file: constant_identifier_names
|
||||
|
||||
import 'package:hgdj/config/config.dart';
|
||||
|
||||
/// lightKV 本地存储 key 集中管理
|
||||
class StoreKeys {
|
||||
// ===== 业务配置 =====
|
||||
/// 资源信息(图片、视频、官网等地址)
|
||||
static const String SOURCE_INFO = "sourceInfo";
|
||||
|
||||
/// 是否保存了二维码图片
|
||||
static const String HAVE_SAVE_QR_CODE = "haveSaveQrCode";
|
||||
|
||||
/// 最近存储的支付宝账号
|
||||
static const String LAST_A_ACCOUNT = "lastAliAcount";
|
||||
|
||||
// ===== 鉴权 / 用户 =====
|
||||
/// 网络 token
|
||||
static const String NET_TOKEN = '_key_net_token';
|
||||
|
||||
/// 用户密码本地锁
|
||||
static const String PASSWORD_LOCK = 'password_key';
|
||||
|
||||
// ===== 设备信息 =====
|
||||
/// 缓存的 User-Agent
|
||||
static const String UA_CACHE = '_key_user_agent';
|
||||
|
||||
/// 本机视频是否需用 platformView 渲染(海思等 TextureView 硬解失败后置位)
|
||||
static const String NEED_PLATFORM_VIEW = '_key_need_platform_view';
|
||||
|
||||
/// 本机是否禁用 H.265(芯片虚报硬解/hev1 封装等,播 265 失败后置位,永久回落 264)
|
||||
static const String H265_DISABLED = '_key_h265_disabled';
|
||||
|
||||
/// 设备 id
|
||||
static const String DEVICE_ID = 'device_id';
|
||||
|
||||
// ===== 网络 / 资源 =====
|
||||
/// 本地 ping 通的线路
|
||||
static const String DETECT_LINE = 'detectLineKey';
|
||||
|
||||
/// 本地广告列表(按 DEBUG 标志区分)
|
||||
static const String ADS_LIST = '_key_ads_list${Config.isDebug}';
|
||||
|
||||
/// 「首次免广告」是否已用掉(adverAbTestShowType == -1,只有第一次进 app 免)
|
||||
static const String AD_FREE_FIRST_USED = 'adFreeFirstUsed';
|
||||
|
||||
// ===== 业务记录 =====
|
||||
/// 视频缓存计数
|
||||
static const String MOVIE_CACHE_COUNT = 'AppMovieCacheCountKey';
|
||||
|
||||
/// 长视频缓存列表
|
||||
static const String MOVIE_CACHE_LIST = 'AppPlayMovieCacheVideoListKey';
|
||||
|
||||
/// 短视频缓存列表
|
||||
static const String SHORT_CACHE_LIST = 'AppPlayShortCacheVideoListKey';
|
||||
|
||||
/// 卡通缓存列表
|
||||
static const String CARTOON_CACHE_LIST = 'AppPlayCartoonCacheVideoListKey';
|
||||
|
||||
/// 短剧缓存列表(按集存)
|
||||
static const String DRAMA_CACHE_LIST = 'AppPlayDramaCacheVideoListKey';
|
||||
|
||||
/// 短剧下载授权的幂等键表:contentId -> X-Request-ID
|
||||
static const String DRAMA_DOWNLOAD_REQUEST_ID =
|
||||
'AppDramaDownloadRequestIdKey';
|
||||
|
||||
/// 免费观看视频列表
|
||||
static const String NEW_FREE_WATCH_VIDEOS = 'new_free_watch_videos';
|
||||
|
||||
// ===== 埋点会话 =====
|
||||
/// 当前 session id
|
||||
static const String TRACK_SESSION_SID = 'track_session_current_sid';
|
||||
|
||||
/// 最近一次事件时间戳
|
||||
static const String TRACK_SESSION_LAST_EVENT_TS =
|
||||
'track_session_last_event_ts';
|
||||
|
||||
/// 进入后台的时间戳
|
||||
static const String TRACK_SESSION_BACKGROUND_TS =
|
||||
'track_session_background_ts';
|
||||
|
||||
// ===== 首页更新红点 =====
|
||||
/// 「最新」Tab 最后查看的服务端更新时间(ISO8601)
|
||||
static const String HOME_LATEST_LAST_VIEW_AT = 'home_latest_last_view_at';
|
||||
|
||||
/// 「今日最新」最后查看的服务端更新时间(ISO8601)
|
||||
static const String HOME_TODAY_LATEST_LAST_VIEW_AT =
|
||||
'home_today_latest_last_view_at';
|
||||
|
||||
/// 首页模块最后查看时间前缀,完整 key = 前缀 + uid + '_' + moduleId
|
||||
static const String HOME_MODULE_LAST_VIEW_AT_PREFIX =
|
||||
'home_module_last_view_at_';
|
||||
|
||||
// ===== 短剧引导气泡 =====
|
||||
/// 已进过短剧 tab,「AI爽剧来袭」气泡永久不再出现
|
||||
static const String DRAMA_TIP_SHOWN = 'drama_tip_shown';
|
||||
|
||||
// ===== VIP 内容上新推送横幅 =====
|
||||
/// 已展示过的内容版本前缀,完整 key = 前缀 + uid(本地兜底去重,防回执未同步时重复弹)
|
||||
static const String VIP_PUSH_SHOWN_VERSION_PREFIX = 'vip_push_shown_version_';
|
||||
}
|
||||
Reference in New Issue
Block a user