Skip to content

AndroidSocket ​

Added in: v1.9

AndroidSocket is a way to communicate with a process launched on the AndroidDevice. Use androidDevice.open() to open a socket.

Methods ​

androidSocket.close() ​

Added in: v1.9 async

Closes the socket.

androidSocket.write() ​

Added in: v1.9 async

Writes some data to the socket.

Arguments

  • data Buffer

    Data to write.

Events ​

androidSocket.on('close') ​

Added in: v1.9

Emitted when the socket is closed.

Event data

  • void

androidSocket.on('data') ​

Added in: v1.9

Emitted when data is available to read from the socket.

Event data

  • Buffer

Released under the Apache 2.0 License.