ReactApplicationContext

A context wrapper that always wraps Android Application Context and by extending ReactContext

Inheritors

Constructors

Link copied to clipboard
constructor(context: Context)

Properties

Link copied to clipboard
val ACCESSIBILITY_SERVICE: String = "accessibility"
Link copied to clipboard
val ACCOUNT_SERVICE: String = "account"
Link copied to clipboard
val ACTIVITY_SERVICE: String = "activity"
Link copied to clipboard
val ALARM_SERVICE: String = "alarm"
Link copied to clipboard
val APP_OPS_SERVICE: String = "appops"
Link copied to clipboard
val APP_SEARCH_SERVICE: String = "app_search"
Link copied to clipboard
val APPWIDGET_SERVICE: String = "appwidget"
Link copied to clipboard
val AUDIO_SERVICE: String = "audio"
Link copied to clipboard
val BATTERY_SERVICE: String = "batterymanager"
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val BIND_EXTERNAL_SERVICE: Int = -2147483648
Link copied to clipboard
val BIND_EXTERNAL_SERVICE_LONG: Long = 4611686018427387904
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val BIOMETRIC_SERVICE: String = "biometric"
Link copied to clipboard
val BLOB_STORE_SERVICE: String = "blob_store"
Link copied to clipboard
val BLUETOOTH_SERVICE: String = "bluetooth"
Link copied to clipboard
val BUGREPORT_SERVICE: String = "bugreport"
Link copied to clipboard
val CAMERA_SERVICE: String = "camera"
Link copied to clipboard
val CAPTIONING_SERVICE: String = "captioning"
Link copied to clipboard
val CARRIER_CONFIG_SERVICE: String = "carrier_config"
Link copied to clipboard
val CLIPBOARD_SERVICE: String = "clipboard"
Link copied to clipboard
val COMPANION_DEVICE_SERVICE: String = "companiondevice"
Link copied to clipboard
val CONNECTIVITY_DIAGNOSTICS_SERVICE: String = "connectivity_diagnostics"
Link copied to clipboard
val CONNECTIVITY_SERVICE: String = "connectivity"
Link copied to clipboard
val CONSUMER_IR_SERVICE: String = "consumer_ir"
Link copied to clipboard
val CONTACT_KEYS_SERVICE: String = "contact_keys"
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val CREDENTIAL_SERVICE: String = "credential"
Link copied to clipboard
val CROSS_PROFILE_APPS_SERVICE: String = "crossprofileapps"
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val DEVICE_LOCK_SERVICE: String = "device_lock"
Link copied to clipboard
val DEVICE_POLICY_SERVICE: String = "device_policy"
Link copied to clipboard
val DISPLAY_HASH_SERVICE: String = "display_hash"
Link copied to clipboard
val DISPLAY_SERVICE: String = "display"
Link copied to clipboard
val DOMAIN_VERIFICATION_SERVICE: String = "domain_verification"
Link copied to clipboard
val DOWNLOAD_SERVICE: String = "download"
Link copied to clipboard
val DROPBOX_SERVICE: String = "dropbox"
Link copied to clipboard
val EUICC_SERVICE: String = "euicc"
Link copied to clipboard
val FILE_INTEGRITY_SERVICE: String = "file_integrity"
Link copied to clipboard
val FINGERPRINT_SERVICE: String = "fingerprint"
Link copied to clipboard
val GAME_SERVICE: String = "game"
Link copied to clipboard
val GRAMMATICAL_INFLECTION_SERVICE: String = "grammatical_inflection"
Link copied to clipboard
val HARDWARE_PROPERTIES_SERVICE: String = "hardware_properties"
Link copied to clipboard
val HEALTHCONNECT_SERVICE: String = "healthconnect"
Link copied to clipboard
val INPUT_METHOD_SERVICE: String = "input_method"
Link copied to clipboard
val INPUT_SERVICE: String = "input"
Link copied to clipboard
val IPSEC_SERVICE: String = "ipsec"
Link copied to clipboard
val JOB_SCHEDULER_SERVICE: String = "jobscheduler"
Link copied to clipboard
val KEYGUARD_SERVICE: String = "keyguard"
Link copied to clipboard
val LAUNCHER_APPS_SERVICE: String = "launcherapps"
Link copied to clipboard
val LAYOUT_INFLATER_SERVICE: String = "layout_inflater"
Link copied to clipboard
val LOCALE_SERVICE: String = "locale"
Link copied to clipboard
val LOCATION_SERVICE: String = "location"
Link copied to clipboard
val MEDIA_COMMUNICATION_SERVICE: String = "media_communication"
Link copied to clipboard
val MEDIA_METRICS_SERVICE: String = "media_metrics"
Link copied to clipboard
val MEDIA_PROJECTION_SERVICE: String = "media_projection"
Link copied to clipboard
val MEDIA_ROUTER_SERVICE: String = "media_router"
Link copied to clipboard
val MEDIA_SESSION_SERVICE: String = "media_session"
Link copied to clipboard
val MIDI_SERVICE: String = "midi"
Link copied to clipboard
val MODE_APPEND: Int = 32768
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val MODE_PRIVATE: Int = 0
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val NETWORK_STATS_SERVICE: String = "netstats"
Link copied to clipboard
val NFC_SERVICE: String = "nfc"
Link copied to clipboard
val NOTIFICATION_SERVICE: String = "notification"
Link copied to clipboard
val NSD_SERVICE: String = "servicediscovery"
Link copied to clipboard
val OVERLAY_SERVICE: String = "overlay"
Link copied to clipboard
val PEOPLE_SERVICE: String = "people"
Link copied to clipboard
val PERFORMANCE_HINT_SERVICE: String = "performance_hint"
Link copied to clipboard
val PERSISTENT_DATA_BLOCK_SERVICE: String = "persistent_data_block"
Link copied to clipboard
val POWER_SERVICE: String = "power"
Link copied to clipboard
val PRINT_SERVICE: String = "print"
Link copied to clipboard
val PROFILING_SERVICE: String = "profiling"
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val RESTRICTIONS_SERVICE: String = "restrictions"
Link copied to clipboard
val ROLE_SERVICE: String = "role"
Link copied to clipboard
val SEARCH_SERVICE: String = "search"
Link copied to clipboard
val SECURITY_STATE_SERVICE: String = "security_state"
Link copied to clipboard
val SENSOR_SERVICE: String = "sensor"
Link copied to clipboard
val SHORTCUT_SERVICE: String = "shortcut"
Link copied to clipboard
val STATUS_BAR_SERVICE: String = "statusbar"
Link copied to clipboard
val STORAGE_SERVICE: String = "storage"
Link copied to clipboard
val STORAGE_STATS_SERVICE: String = "storagestats"
Link copied to clipboard
val SYSTEM_HEALTH_SERVICE: String = "systemhealth"
Link copied to clipboard
val TELECOM_SERVICE: String = "telecom"
Link copied to clipboard
val TELEPHONY_IMS_SERVICE: String = "telephony_ims"
Link copied to clipboard
val TELEPHONY_SERVICE: String = "phone"
Link copied to clipboard
val TELEPHONY_SUBSCRIPTION_SERVICE: String = "telephony_subscription_service"
Link copied to clipboard
val TEXT_CLASSIFICATION_SERVICE: String = "textclassification"
Link copied to clipboard
Link copied to clipboard
val TV_INPUT_SERVICE: String = "tv_input"
Link copied to clipboard
val TV_INTERACTIVE_APP_SERVICE: String = "tv_interactive_app"
Link copied to clipboard
val UI_MODE_SERVICE: String = "uimode"
Link copied to clipboard
val USAGE_STATS_SERVICE: String = "usagestats"
Link copied to clipboard
val USB_SERVICE: String = "usb"
Link copied to clipboard
val USER_SERVICE: String = "user"
Link copied to clipboard
val VIBRATOR_MANAGER_SERVICE: String = "vibrator_manager"
Link copied to clipboard
val VIBRATOR_SERVICE: String = "vibrator"
Link copied to clipboard
val VIRTUAL_DEVICE_SERVICE: String = "virtualdevice"
Link copied to clipboard
val VPN_MANAGEMENT_SERVICE: String = "vpn_management"
Link copied to clipboard
val WALLPAPER_SERVICE: String = "wallpaper"
Link copied to clipboard
val WIFI_AWARE_SERVICE: String = "wifiaware"
Link copied to clipboard
val WIFI_P2P_SERVICE: String = "wifip2p"
Link copied to clipboard
Link copied to clipboard
val WIFI_SERVICE: String = "wifi"
Link copied to clipboard
val WINDOW_SERVICE: String = "window"

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun bindIsolatedService(service: Intent, flags: Int, instanceName: String, executor: Executor, conn: ServiceConnection): Boolean
Link copied to clipboard
open fun bindService(service: Intent, conn: ServiceConnection, flags: Int): Boolean
Link copied to clipboard
open fun bindServiceAsUser(service: Intent, conn: ServiceConnection, flags: Int, user: UserHandle): Boolean
Link copied to clipboard
open fun checkCallingOrSelfPermission(permission: String): Int
Link copied to clipboard
open fun checkCallingOrSelfUriPermission(uri: Uri, modeFlags: Int): Int
Link copied to clipboard
open fun checkCallingOrSelfUriPermissions(uris: List<Uri>, modeFlags: Int): Array<Int>
Link copied to clipboard
open fun checkCallingPermission(permission: String): Int
Link copied to clipboard
open fun checkCallingUriPermission(uri: Uri, modeFlags: Int): Int
Link copied to clipboard
open fun checkCallingUriPermissions(uris: List<Uri>, modeFlags: Int): Array<Int>
Link copied to clipboard
open fun checkContentUriPermissionFull(uri: Uri, pid: Int, uid: Int, modeFlags: Int): Int
Link copied to clipboard
open fun checkPermission(permission: String, pid: Int, uid: Int): Int
Link copied to clipboard
open fun checkSelfPermission(permission: String): Int
Link copied to clipboard
open fun checkUriPermission(uri: Uri, pid: Int, uid: Int, modeFlags: Int): Int
Link copied to clipboard
open fun checkUriPermissions(uris: List<Uri>, pid: Int, uid: Int, modeFlags: Int): Array<Int>
Link copied to clipboard
open fun clearWallpaper()
Link copied to clipboard
open fun createAttributionContext(attributionTag: String): Context
Link copied to clipboard
open fun createConfigurationContext(overrideConfiguration: Configuration): Context
Link copied to clipboard
open fun createContext(contextParams: ContextParams): Context
Link copied to clipboard
open fun createContextForSplit(splitName: String): Context
Link copied to clipboard
open fun createDeviceContext(deviceId: Int): Context
Link copied to clipboard
Link copied to clipboard
open fun createPackageContext(packageName: String, flags: Int): Context
Link copied to clipboard
open fun createWindowContext(type: Int, options: Bundle): Context
Link copied to clipboard
Link copied to clipboard
open fun deleteDatabase(name: String): Boolean
Link copied to clipboard
open fun deleteFile(name: String): Boolean
Link copied to clipboard
Link copied to clipboard
abstract fun destroy()
Destroy this instance, making it unusable.
Link copied to clipboard
open fun emitDeviceEvent(eventName: String)

open fun emitDeviceEvent(eventName: String, @Nullable args: Any)
Calls RCTDeviceEventEmitter.emit to JavaScript, with given event name and an optional list of arguments.
Link copied to clipboard
open fun enforceCallingOrSelfPermission(permission: String, message: String)
Link copied to clipboard
open fun enforceCallingOrSelfUriPermission(uri: Uri, modeFlags: Int, message: String)
Link copied to clipboard
open fun enforceCallingPermission(permission: String, message: String)
Link copied to clipboard
open fun enforceCallingUriPermission(uri: Uri, modeFlags: Int, message: String)
Link copied to clipboard
open fun enforcePermission(permission: String, pid: Int, uid: Int, message: String)
Link copied to clipboard
open fun enforceUriPermission(uri: Uri, pid: Int, uid: Int, modeFlags: Int, message: String)
Link copied to clipboard
open fun fileList(): Array<String>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getCacheDir(): File
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getCodeCacheDir(): File
Link copied to clipboard
fun getColor(id: Int): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Get the activity to which this context is currently attached, or null if not attached.
Link copied to clipboard
open fun getDatabasePath(name: String): File
Link copied to clipboard
open fun getDataDir(): File
Link copied to clipboard
open fun getDeviceId(): Int
Link copied to clipboard
open fun getDir(name: String, mode: Int): File
Link copied to clipboard
open fun getDisplay(): Display
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getFilesDir(): File
Link copied to clipboard
open fun getFileStreamPath(name: String): File
Link copied to clipboard
Get the C pointer (as a long) to the JavaScriptCore context associated with this instance.
Link copied to clipboard
Returns a hybrid object that contains a pointer to a JS CallInvoker, which is used to schedule work on the JS Thread.
Link copied to clipboard
Link copied to clipboard
abstract fun <T : JavaScriptModule?> getJSModule(jsInterface: Class<T>): T
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getMainLooper(): Looper
Link copied to clipboard
abstract fun <T : NativeModule?> getNativeModule(nativeModuleInterface: Class<T>): T
abstract fun getNativeModule(moduleName: String): NativeModule
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getObbDir(): File
Link copied to clipboard
open fun getObbDirs(): Array<File>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract fun getSourceURL(): String
Get the sourceURL for the JS bundle from the CatalystInstance.
Link copied to clipboard
fun getString(resId: Int): String
Link copied to clipboard
fun <T> getSystemService(serviceClass: Class<T>): T
open fun getSystemService(name: String): Any
open fun getSystemService(name: String): Any
Link copied to clipboard
open fun getSystemServiceName(serviceClass: Class<out Any>): String
Link copied to clipboard
fun getText(resId: Int): CharSequence
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun grantUriPermission(toPackage: String, uri: Uri, modeFlags: Int)
Link copied to clipboard
abstract fun handleException(e: Exception)
Passes the given exception to the current JSExceptionHandler if one exists, rethrowing otherwise.
Link copied to clipboard
This API has been deprecated due to naming consideration, please use hasActiveReactInstance() instead
Link copied to clipboard
Link copied to clipboard
This API has been deprecated due to naming consideration, please use hasReactInstance() instead
Link copied to clipboard
Link copied to clipboard
abstract fun <T : NativeModule?> hasNativeModule(nativeModuleInterface: Class<T>): Boolean
Link copied to clipboard
abstract fun hasReactInstance(): Boolean
Link copied to clipboard
Initialize message queue threads using a ReactQueueConfiguration.
Link copied to clipboard
open fun <T : JavaScriptModule?> internal_registerInteropModule(interopModuleInterface: Class<T>, interopModule: Any)
Register a JavaScriptModule within the Interop Layer so that can be consumed whenever getJSModule is invoked.
Link copied to clipboard
abstract fun isBridgeless(): Boolean
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun isRestricted(): Boolean
Link copied to clipboard
open fun isUiContext(): Boolean
Link copied to clipboard
open fun moveDatabaseFrom(sourceContext: Context, name: String): Boolean
Link copied to clipboard
open fun moveSharedPreferencesFrom(sourceContext: Context, name: String): Boolean
Link copied to clipboard
Link copied to clipboard
open fun onActivityResult(activity: Activity, requestCode: Int, resultCode: Int, @Nullable data: Intent)
Should be called by the hosting Fragment in onActivityResult
Link copied to clipboard
open fun onHostDestroy()
Should be called by the hosting Fragment in onDestroy
open fun onHostDestroy(keepActivity: Boolean)
Link copied to clipboard
open fun onHostPause()
Should be called by the hosting Fragment in onPause
Link copied to clipboard
open fun onHostResume(@Nullable activity: Activity)
Should be called by the hosting Fragment in onResume
Link copied to clipboard
open fun onNewIntent(@Nullable activity: Activity, intent: Intent)
Link copied to clipboard
open fun onUserLeaveHint(@Nullable activity: Activity)
Link copied to clipboard
open fun onWindowFocusChange(hasFocus: Boolean)
Link copied to clipboard
Link copied to clipboard
open fun openFileOutput(name: String, mode: Int): FileOutputStream
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun registerDeviceIdChangeListener(executor: Executor, listener: IntConsumer)
Link copied to clipboard
Link copied to clipboard
abstract fun registerSegment(segmentId: Int, path: String, callback: Callback)
Register a JS segment after loading it from cache or server, make sure mCatalystInstance is properly initialised and not null before calling.
Link copied to clipboard
open fun removeStickyBroadcast(intent: Intent)
Link copied to clipboard
Link copied to clipboard
open fun resetPerfStats()
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun revokeUriPermission(uri: Uri, modeFlags: Int)
Link copied to clipboard
open fun runOnJSQueueThread(runnable: Runnable): Boolean
Link copied to clipboard
Link copied to clipboard
open fun runOnUiQueueThread(runnable: Runnable)
Link copied to clipboard
open fun sendBroadcast(intent: Intent)
Link copied to clipboard
open fun sendBroadcastAsUser(intent: Intent, user: UserHandle)
Link copied to clipboard
open fun sendBroadcastWithMultiplePermissions(intent: Intent, receiverPermissions: Array<String>)
Link copied to clipboard
open fun sendOrderedBroadcast(intent: Intent, receiverPermission: String)
Link copied to clipboard
open fun sendOrderedBroadcastAsUser(intent: Intent, user: UserHandle, receiverPermission: String, resultReceiver: BroadcastReceiver, scheduler: Handler, initialCode: Int, initialData: String, initialExtras: Bundle)
Link copied to clipboard
open fun sendStickyBroadcast(intent: Intent)
Link copied to clipboard
Link copied to clipboard
open fun sendStickyOrderedBroadcast(intent: Intent, resultReceiver: BroadcastReceiver, scheduler: Handler, initialCode: Int, initialData: String, initialExtras: Bundle)
Link copied to clipboard
open fun sendStickyOrderedBroadcastAsUser(intent: Intent, user: UserHandle, resultReceiver: BroadcastReceiver, scheduler: Handler, initialCode: Int, initialData: String, initialExtras: Bundle)
Link copied to clipboard
open fun setJSExceptionHandler(@Nullable jSExceptionHandler: JSExceptionHandler)
Link copied to clipboard
open fun setTheme(resid: Int)
Link copied to clipboard
open fun setWallpaper(bitmap: Bitmap)
Link copied to clipboard
open fun startActivities(intents: Array<Intent>)
Link copied to clipboard
open fun startActivity(intent: Intent)
Link copied to clipboard
open fun startActivityForResult(intent: Intent, code: Int, bundle: Bundle): Boolean
Same as startActivityForResult, this just redirects the call to the current activity.
Link copied to clipboard
Link copied to clipboard
open fun startInstrumentation(className: ComponentName, profileFile: String, arguments: Bundle): Boolean
Link copied to clipboard
open fun startIntentSender(intent: IntentSender, fillInIntent: Intent, flagsMask: Int, flagsValues: Int, extraFlags: Int)
Link copied to clipboard
open fun startService(service: Intent): ComponentName
Link copied to clipboard
open fun stopService(name: Intent): Boolean
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun updateServiceGroup(conn: ServiceConnection, group: Int, importance: Int)