简体   繁体   English

如何锁定和解锁 android 中的文件夹

[英]How to lock and unlock a folder in android

I am just starting with Android.我只是从 Android 开始。 And my boss told me to find some good way to lock/unlock a folder with password in Android.我的老板告诉我在 Android 中找到一些用密码锁定/解锁文件夹的好方法。 Does anybody know how to implement this.有谁知道如何实现这一点。 Any help will be greatly appreciated.任何帮助将不胜感激。

Thank you谢谢

In Android you only have "one user", (you have root too, but here doesnt count), so you cant lock a folder, because its your self.在 Android 中,您只有“一个用户”,(您也有 root,但这里不算),所以您不能锁定文件夹,因为它是您自己的。 But if you are use one file with permisson to write, other app cant write.但是,如果您使用一个具有写入权限的文件,则其他应用程序将无法写入。 And if you want make something that you only open with a pass, like a FoldeGuard, you can make a file, that have your information with some Formatter, and You are the only person that can open that file, you can too asociate the file with you app and open automatically your app.如果您想制作只能通过通行证打开的东西,例如 FoldeGuard,您可以制作一个文件,其中包含一些格式化程序的信息,并且您是唯一可以打开该文件的人,您也可以关联该文件与您的应用程序并自动打开您的应用程序。 So the simple way for me is, make a BD, that there you have all information you need and put password in the bd, or make a file that you asociate your app, and later when you open a file and put the pass you extract all information for a folder... I hope that ideas help you:)所以对我来说最简单的方法是,制作一个BD,在那里你有你需要的所有信息并将密码输入到bd中,或者制作一个你关联你的应用程序的文件,然后当你打开一个文件并输入你提取的通行证文件夹的所有信息...我希望这些想法对您有所帮助:)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM