MCPcopy Create free account
hub / github.com/NativeScript/NativeScript / getResource

Function getResource

packages/core/utils/native-helper-for-android.ts:258–260  ·  view source on GitHub ↗
(name: string, type?: string)

Source from the content-addressed store, hash-verified

256 return resources.getIdentifier(uri, null, null);
257 }
258 export function getResource(name: string, type?: string): number {
259 return getResources().getIdentifier(name, type, getPackageName());
260 }
261 export function getPaletteColor(name: string, context: android.content.Context): number {
262 if (attrCache.has(name)) {
263 return attrCache.get(name);

Callers

nothing calls this directly

Calls 2

getResourcesFunction · 0.85
getPackageNameFunction · 0.85

Tested by

no test coverage detected