PackageUtils

Properties

Link copied to clipboard
private var packageName: String?

Functions

Link copied to clipboard
fun getResourcePackageName(context: Context): String

Utility method for getting the resource package name; returns the value set in setResourcePackageName, or Context.getPackageName if no custom value has been set.

Link copied to clipboard
fun setResourcePackageName(packageName: String)

Utility method for setting the package name that will be used to look up resources dynamically at runtime. This method is for non standard use cases and should only be used if you are consciously modifying package names at compile time.