AutoJs
globals AutoJs
Runtime handle for the packaged/host Auto.js Pro environment.
Table of contents
Properties
Methods
Properties
androidContext
- androidContext:
Context
Current Android Context.
application
- application:
Application
Host Application instance.
isReleaseMode
- isReleaseMode:
boolean
true when running inside a released / packaged app; false when running inside the Auto.js Pro host app.
java
- java:
Java
Low-level Java interop entry point. Prefer the packaged java / rhino modules for normal use.
properties
- properties:
ReadonlyMap<string, any>
Read-only build/runtime property map.
Methods
cancelKeepRunning
cancelKeepRunning(id: number): any
Stops a previous keepRunning token so the Node.js event loop can exit when appropriate.
See also
Parameters
id: Value returned bykeepRunning().
Returns
any
keepRunning
keepRunning(): number
Pins the engine so the Node.js event loop does not drain. Returns an id passed to cancelKeepRunning. If keepRunning is called multiple times, the loop stays alive until every id is cancelled.
Returns
number
Opaque id for cancelKeepRunning.
requireAutoJsVersion
requireAutoJsVersion(version: string): any
Throws if the current Auto.js Pro build is older than version.
Parameters
version: Required version string, e.g."Pro 9.1.0-2".
Returns
any
