我试图设置一个文件提供程序来访问使用Intent拍摄的图像。 但是,当尝试在清单中定义它时,该名称不会被识别。 问题所在就是第三行中的...“文件提供者”。
<provider
android:authorities="androidx.core.content.FileProvider"
android:name="com.mobila.project.today.fileprovider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/file_paths" />
</provider>
据我了解,.fileprovider之前的部分应与我的软件包匹配。但是它的名字看起来像这样:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.mobila.project.today">
我该如何解决?有没有使用fileprovider的解决方法,例如,我可以将图片直接保存在ArrayList中?