Home
last modified time | relevance | path

Searched refs:ApkAssets (Results 1 – 25 of 46) sorted by relevance

12

/frameworks/base/core/java/android/content/res/loader/
DResourcesProvider.java26 import android.content.res.ApkAssets;
60 private final ApkAssets mApkAssets;
70 return new ResourcesProvider(ApkAssets.loadEmptyForLoader(ApkAssets.PROPERTY_LOADER, in empty()
111 ApkAssets.loadOverlayFromPath( in loadOverlay()
151 return new ResourcesProvider(ApkAssets.loadFromFd(fileDescriptor.getFileDescriptor(), in loadFromApk()
152 fileDescriptor.toString(), ApkAssets.PROPERTY_LOADER, assetsProvider)); in loadFromApk()
180 return new ResourcesProvider(ApkAssets.loadFromFd(fileDescriptor.getFileDescriptor(), in loadFromApk()
181 fileDescriptor.toString(), offset, length, ApkAssets.PROPERTY_LOADER, in loadFromApk()
206 ApkAssets.loadTableFromFd(fileDescriptor.getFileDescriptor(), in loadFromTable()
207 fileDescriptor.toString(), ApkAssets.PROPERTY_LOADER, assetsProvider)); in loadFromTable()
[all …]
DResourcesLoader.java20 import android.content.res.ApkAssets;
58 private ApkAssets[] mApkAssets;
160 public List<ApkAssets> getApkAssets() { in getApkAssets()
241 mApkAssets = new ApkAssets[mProviders.length]; in notifyProvidersChangedLocked()
/frameworks/base/core/java/android/content/res/
DApkAssets.java48 public final class ApkAssets { class
138 public static @NonNull ApkAssets loadFromPath(@NonNull String path) throws IOException { in loadFromPath()
150 public static @NonNull ApkAssets loadFromPath(@NonNull String path, @PropertyFlags int flags) in loadFromPath()
152 return new ApkAssets(FORMAT_APK, path, flags, null /* assets */); in loadFromPath()
164 public static @NonNull ApkAssets loadFromPath(@NonNull String path, @PropertyFlags int flags, in loadFromPath()
166 return new ApkAssets(FORMAT_APK, path, flags, assets); in loadFromPath()
182 public static @NonNull ApkAssets loadFromFd(@NonNull FileDescriptor fd, in loadFromFd()
185 return new ApkAssets(FORMAT_APK, fd, friendlyName, flags, assets); in loadFromFd()
205 public static @NonNull ApkAssets loadFromFd(@NonNull FileDescriptor fd, in loadFromFd()
209 return new ApkAssets(FORMAT_APK, fd, friendlyName, offset, length, flags, assets); in loadFromFd()
[all …]
DAssetManager.java77 private static final ApkAssets[] sEmptyApkAssets = new ApkAssets[0];
83 @GuardedBy("sSync") private static ApkAssets[] sSystemApkAssets = new ApkAssets[0];
84 @GuardedBy("sSync") private static ArraySet<ApkAssets> sSystemApkAssetsSet;
122 @GuardedBy("this") private ApkAssets[] mApkAssets;
140 private ArrayList<ApkAssets> mUserApkAssets = new ArrayList<>();
145 public Builder addApkAssets(ApkAssets apkAssets) { in addApkAssets()
162 final ApkAssets[] systemApkAssets = getSystem().getApkAssets(); in build()
167 final ArrayList<ApkAssets> loaderApkAssets = new ArrayList<>(); in build()
168 final ArraySet<ApkAssets> uniqueLoaderApkAssets = new ArraySet<>(); in build()
170 final List<ApkAssets> currentLoaderApkAssets = mLoaders.get(i).getApkAssets(); in build()
[all …]
/frameworks/base/core/java/com/android/internal/pm/split/
DSplitAssetDependencyLoader.java22 import android.content.res.ApkAssets;
45 private final ApkAssets[][] mCachedSplitApks;
58 mCachedSplitApks = new ApkAssets[mSplitPaths.length][]; in SplitAssetDependencyLoader()
67 private static ApkAssets loadApkAssets(String path, @ParseFlags int flags) in loadApkAssets()
75 return ApkAssets.loadFromPath(path); in loadApkAssets()
81 private static AssetManager createAssetManagerWithAssets(ApkAssets[] apkAssets) { in createAssetManagerWithAssets()
92 final ArrayList<ApkAssets> assets = new ArrayList<>(); in constructSplit()
108 mCachedSplitApks[splitIdx] = assets.toArray(new ApkAssets[assets.size()]); in constructSplit()
127 public ApkAssets getBaseApkAssets() { in getBaseApkAssets()
DDefaultSplitAssetLoader.java20 import android.content.res.ApkAssets;
42 private ApkAssets mBaseApkAssets;
50 private static ApkAssets loadApkAssets(String path, @ParseFlags int flags) in loadApkAssets()
58 return ApkAssets.loadFromPath(path); in loadApkAssets()
70 ApkAssets[] apkAssets = new ApkAssets[(mSplitApkPaths != null in getBaseAssetManager()
99 public ApkAssets getBaseApkAssets() { in getBaseApkAssets()
DSplitAssetLoader.java18 import android.content.res.ApkAssets;
31 ApkAssets getBaseApkAssets(); in getBaseApkAssets()
/frameworks/base/libs/androidfw/
DApkAssets.cpp30 ApkAssets::ApkAssets(PrivateConstructorUtil, std::unique_ptr<Asset> resources_asset, in ApkAssets() function in android::ApkAssets
42 ApkAssetsPtr ApkAssets::Load(const std::string& path, package_property_t flags) { in Load()
46 ApkAssetsPtr ApkAssets::LoadFromFd(base::unique_fd fd, const std::string& debug_name, in LoadFromFd()
51 ApkAssetsPtr ApkAssets::Load(std::unique_ptr<AssetsProvider> assets, package_property_t flags) { in Load()
55 ApkAssetsPtr ApkAssets::LoadTable(std::unique_ptr<Asset> resources_asset, in LoadTable()
65 ApkAssetsPtr ApkAssets::LoadOverlay(const std::string& idmap_path, package_property_t flags) { in LoadOverlay()
100 ApkAssetsPtr ApkAssets::LoadImpl(std::unique_ptr<AssetsProvider> assets, in LoadImpl()
122 ApkAssetsPtr ApkAssets::LoadImpl(std::unique_ptr<Asset> resources_asset, in LoadImpl()
156 std::optional<std::string_view> ApkAssets::GetPath() const { in GetPath()
160 const std::string& ApkAssets::GetDebugName() const { in GetDebugName()
[all …]
/frameworks/base/libs/androidfw/tests/
DApkAssets_test.cpp38 auto loaded_apk = ApkAssets::Load(GetTestDataPath() + "/basic/basic.apk"); in TEST()
52 auto loaded_apk = ApkAssets::LoadFromFd(std::move(fd), path); in TEST()
62 auto loaded_apk = ApkAssets::Load(GetTestDataPath() + "/appaslib/appaslib.apk"); in TEST()
70 loaded_apk = ApkAssets::Load(GetTestDataPath() + "/appaslib/appaslib.apk", PROPERTY_DYNAMIC); in TEST()
80 auto loaded_apk = ApkAssets::Load(GetTestDataPath() + "/basic/basic.apk"); in TEST()
91 auto loaded_apk = ApkAssets::Load(GetTestDataPath() + "/basic/basic.apk"); in TEST()
DAssetManager2_bench.cpp41 auto apk = ApkAssets::Load(path); in BM_AssetManagerLoadAssets()
64 auto apk = ApkAssets::Load(path); in BM_AssetManagerLoadFrameworkAssets()
132 auto apk = ApkAssets::Load(GetTestDataPath() + "/styles/styles.apk"); in BM_AssetManagerGetBag()
184 auto apk = ApkAssets::Load(kFrameworkPath); in BM_AssetManagerGetResourceLocales()
220 auto apk = ApkAssets::Load(kFrameworkPath); in BM_AssetManagerSetConfigurationFramework()
DIdmap_test.cpp46 system_assets_ = ApkAssets::Load("system/system.apk"); in SetUp()
49 overlay_assets_ = ApkAssets::LoadOverlay("overlay/overlay.idmap"); in SetUp()
52 overlayable_assets_ = ApkAssets::Load("overlayable/overlayable.apk"); in SetUp()
196 auto loader_assets = ApkAssets::LoadTable(std::move(asset), EmptyAssetsProvider::Create(), in TEST_F()
215 auto apk_assets = ApkAssets::LoadOverlay(temp_file.path); in TEST_F()
DAttributeResolution_bench.cpp39 auto styles_apk = ApkAssets::Load(GetTestDataPath() + "/styles/styles.apk"); in BM_ApplyStyle()
82 auto framework_apk = ApkAssets::Load(kFrameworkPath); in BM_ApplyStyleFramework()
88 auto basic_apk = ApkAssets::Load(GetTestDataPath() + "/basic/basic.apk"); in BM_ApplyStyleFramework()
DTheme_bench.cpp31 auto apk = ApkAssets::Load(kFrameworkPath); in BM_ThemeApplyStyleFramework()
65 auto apk = ApkAssets::Load(kFrameworkPath); in BM_ThemeGetAttribute()
DAssetManager2_test.cpp52 basic_assets_ = ApkAssets::Load("basic/basic.apk"); in SetUp()
55 basic_de_fr_assets_ = ApkAssets::Load("basic/basic_de_fr.apk"); in SetUp()
58 basic_xhdpi_assets_ = ApkAssets::Load("basic/basic_xhdpi-v4.apk"); in SetUp()
61 basic_xxhdpi_assets_ = ApkAssets::Load("basic/basic_xxhdpi-v4.apk"); in SetUp()
64 style_assets_ = ApkAssets::Load("styles/styles.apk"); in SetUp()
67 lib_one_assets_ = ApkAssets::Load("lib_one/lib_one.apk"); in SetUp()
70 lib_two_assets_ = ApkAssets::Load("lib_two/lib_two.apk"); in SetUp()
73 libclient_assets_ = ApkAssets::Load("libclient/libclient.apk"); in SetUp()
76 appaslib_assets_ = ApkAssets::Load("appaslib/appaslib.apk", PROPERTY_DYNAMIC); in SetUp()
79 system_assets_ = ApkAssets::Load("system/system.apk", PROPERTY_SYSTEM); in SetUp()
[all …]
DTheme_test.cpp39 system_assets_ = ApkAssets::Load(GetTestDataPath() + "/system/system.apk", PROPERTY_SYSTEM); in SetUp()
42 style_assets_ = ApkAssets::Load(GetTestDataPath() + "/styles/styles.apk"); in SetUp()
45 libclient_assets_ = ApkAssets::Load(GetTestDataPath() + "/libclient/libclient.apk"); in SetUp()
48 lib_one_assets_ = ApkAssets::Load(GetTestDataPath() + "/lib_one/lib_one.apk"); in SetUp()
51 lib_two_assets_ = ApkAssets::Load(GetTestDataPath() + "/lib_two/lib_two.apk"); in SetUp()
/frameworks/base/libs/androidfw/include/androidfw/
DApkAssets.h35 class ApkAssets; variable
37 using ApkAssetsPtr = sp<ApkAssets>;
40 class ApkAssets : public RefBase {
116 ApkAssets(PrivateConstructorUtil, std::unique_ptr<Asset> resources_asset,
/frameworks/base/core/jni/
Dandroid_content_res_ApkAssets.cpp238 apk_assets = ApkAssets::Load(std::move(assets), property_flags); in NativeLoad()
242 apk_assets = ApkAssets::LoadOverlay(path.c_str(), property_flags); in NativeLoad()
245 apk_assets = ApkAssets::LoadTable(AssetsProvider::CreateAssetFromFile(path.c_str()), in NativeLoad()
252 apk_assets = ApkAssets::Load(std::move(assets), property_flags); in NativeLoad()
300 apk_assets = ApkAssets::Load(std::move(assets), property_flags); in NativeLoadFromFd()
304 apk_assets = ApkAssets::LoadTable( in NativeLoadFromFd()
370 apk_assets = ApkAssets::Load(std::move(assets), property_flags); in NativeLoadFromFdOffset()
374 apk_assets = ApkAssets::LoadTable( in NativeLoadFromFdOffset()
396 auto apk_assets = ApkAssets::Load(LoaderAssetsProvider::Create(env, assets_provider), flags); in NativeLoadEmpty()
/frameworks/base/cmds/idmap2/idmap2/
DLookup.cpp43 using android::ApkAssets;
191 auto target_apk = ApkAssets::Load(target_path); in Lookup()
213 auto overlay_apk = ApkAssets::LoadOverlay(idmap_path); in Lookup()
/frameworks/base/packages/SystemUI/src/com/android/systemui/navigationbar/
DNavigationModeController.java27 import android.content.res.ApkAssets;
214 ApkAssets[] assets = context.getResources().getAssets().getApkAssets(); in dumpAssetPaths()
215 for (ApkAssets a : assets) { in dumpAssetPaths()
/frameworks/base/libs/androidfw/fuzz/resourcefile_fuzzer/
Dresourcefile_fuzzer.cpp29 using android::ApkAssets;
/frameworks/base/core/java/android/app/
DResourcesManager.java28 import android.content.res.ApkAssets;
233 final ArrayMap<ApkKey, ApkAssets> mLocalCache = new ArrayMap<>();
240 ApkAssets load(final ApkKey apkKey) throws IOException { in load()
241 ApkAssets apkAssets = mLocalCache.get(apkKey); in load()
254 private final ArrayMap<ApkKey, WeakReference<ApkAssets>> mCachedApkAssets = new ArrayMap<>();
396 final List<ApkAssets> assetsToClose = new ArrayList<>(); in invalidatePath()
401 final WeakReference<ApkAssets> apkAssetsRef = mCachedApkAssets.removeAt(i); in invalidatePath()
402 final ApkAssets apkAssets = apkAssetsRef != null ? apkAssetsRef.get() : null; in invalidatePath()
543 public @NonNull ApkAssets loadApkAssets(@NonNull final ApkKey key) throws IOException { in loadApkAssets()
544 ApkAssets apkAssets; in loadApkAssets()
[all …]
/frameworks/base/cmds/idmap2/include/idmap2/
DPrettyPrintVisitor.h28 class ApkAssets; variable
DRawPrintVisitor.h29 class ApkAssets; variable
/frameworks/base/core/tests/coretests/src/android/content/res/
DResourcesManagerTest.java380 ApkAssets[] loadedAssets = resources.getAssets().getApkAssets(); in testExistingResourcesAfterResourcePathsRegistration()
411 ApkAssets[] loadedAssets = resources.getAssets().getApkAssets(); in testNewResourcesAfterResourcePathsRegistration()
447 ApkAssets[] loadedAssets = resources.getAssets().getApkAssets(); in testExistingResourcesCreatedByConstructorAfterResourcePathsRegistration()
486 ApkAssets[] loadedAssets = resources.getAssets().getApkAssets(); in testNewResourcesWithOutdatedImplAfterResourcePathsRegistration()
495 private static boolean allResourcePathsLoaded(String[] resourcePaths, ApkAssets[] loadedAsset) { in allResourcePathsLoaded()
/frameworks/base/cmds/idmap2/tests/
DResourceUtilsTests.cpp38 apk_assets_ = ApkAssets::Load(GetTargetApkPath()); in SetUp()

12