惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

WordPress大学
WordPress大学
Project Zero
Project Zero
Engineering at Meta
Engineering at Meta
Microsoft Azure Blog
Microsoft Azure Blog
小众软件
小众软件
T
The Blog of Author Tim Ferriss
S
SegmentFault 最新的问题
量子位
V
Visual Studio Blog
F
Full Disclosure
博客园 - 叶小钗
Recent Announcements
Recent Announcements
G
Google Developers Blog
博客园 - Franky
F
Fortinet All Blogs
有赞技术团队
有赞技术团队
B
Blog
aimingoo的专栏
aimingoo的专栏
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
N
Netflix TechBlog - Medium
L
LINUX DO - 最新话题
S
Security @ Cisco Blogs
Google DeepMind News
Google DeepMind News
B
Blog RSS Feed
Cloudbric
Cloudbric
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
Last Week in AI
Last Week in AI
SecWiki News
SecWiki News
H
Hackread – Cybersecurity News, Data Breaches, AI and More
云风的 BLOG
云风的 BLOG
阮一峰的网络日志
阮一峰的网络日志
N
News and Events Feed by Topic
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
Microsoft Security Blog
Microsoft Security Blog
D
DataBreaches.Net
人人都是产品经理
人人都是产品经理
Schneier on Security
Schneier on Security
Webroot Blog
Webroot Blog
T
Troy Hunt's Blog
P
Proofpoint News Feed
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Jina AI
Jina AI
PCI Perspectives
PCI Perspectives
Martin Fowler
Martin Fowler
O
OpenAI News
Hacker News: Ask HN
Hacker News: Ask HN
S
Secure Thoughts
P
Privacy International News Feed
I
InfoQ
C
Cyber Attacks, Cyber Crime and Cyber Security

博客园 - 邢帅杰

.net core使用SharpZipLib压缩zip文件并设置密码 CSRedisCore用法 安卓把assets中的文件copy到app目录中 oracle执行sql语句前清除缓存 安卓开发使用interface自定义回调函数 安装DockerDesktop并启用 oracle中decode用法 vue使用import.meta编译报错,import.meta.env报:类型“ImportMeta”上不存在属性“env”。必须配置module。 oracle游标使用详解 oracle存储过程中声明一个行变量,接收游标中的行数据。variable_name table_name%ROWTYPE oracle NVL和NVL2 C#获取文件md5码 oracle查询存储过程和函数中是否包含某个字符串 Android清除WebView缓存 C#获取当前日期是星期几 切换项目git地址,项目迁移到新git地址 C#线程同步、跨进程同步Mutex详解、C#只允许运行一个实例 Android Stack说明 安卓打开第三方app并传入参数 安卓如何唤醒深度睡眠的设备并执行任务 java两个日期相差秒数
Android 常用数据目录(内部 / 外部、缓存、文件) 的 获取方法对照表
邢帅杰 · 2026-04-17 · via 博客园 - 邢帅杰

code

            // 真实路径 /data/user/0/包名/databases/1.txt
            // 软链接路径 /data/data/包名/databases/1.txt
            File targetFile = getDatabasePath("1.txt");
            // 应用私有内部存储 /data/user/0/包名/files
            getFilesDir().getAbsolutePath();
            // 应用缓存目录(系统可自动清理) /data/user/0/包名/cache
            getCacheDir().getAbsolutePath();
            // 自定义私有目录 /data/user/0/包名/app_my_dir
            getDir("my_dir", Context.MODE_PRIVATE).getAbsolutePath();
            // 外部私有目录(卸载自动删除,无需权限)
            // 应用私有 外部文件 /storage/emulated/0/Android/data/包名/files
            getExternalFilesDir(null).getAbsolutePath();
            // 应用私有 外部缓存 /storage/emulated/0/Android/data/包名/cache
            getExternalCacheDir().getAbsolutePath();
            //外部公共目录(照片、下载、音乐等) /storage/emulated/0/Download
            Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS).getAbsolutePath();

外部公共目录,可选类型:
DIRECTORY_DCIM
DIRECTORY_PICTURES
DIRECTORY_MUSIC
DIRECTORY_MOVIES
DIRECTORY_DOWNLOADS
DIRECTORY_DOCUMENTS