DevToolsConfig

data class DevToolsConfig(val serverUrl: String? = null, val enabled: Boolean = true, val autoConnect: Boolean = true, val autoReconnect: Boolean = true, val allowActionCapture: Boolean = true, val allowStateCapture: Boolean = true, val defaultRole: ClientRole? = null, val allowRemoteRequests: Boolean = true)(source)

Configuration for the DevTools service.

Client identity (clientId, clientName, platform) comes from the tooling module's IntrospectionConfig, so it never needs to be repeated here.

Example usage:

val config = DevToolsConfig(
serverUrl = "ws://192.168.1.100:8080/ws",
defaultRole = ClientRole.PUBLISHER
)

Example usage for manual connection timing:

val config = DevToolsConfig(
serverUrl = "ws://192.168.1.100:8080/ws",
autoConnect = false
)

// Later, from a debug menu:
dispatch(ToolingAction.ServiceCommand("devtools", "connect", mapOf("role" to "PUBLISHER")))

Parameters

serverUrl

WebSocket server URL. Null means no connection until connect is called with a URL

enabled

Enable/disable DevTools functionality

autoConnect

Connect on service start when true; wait for an explicit connect when false

allowActionCapture

Allow sending dispatched actions to the DevTools server

allowStateCapture

Allow sending state changes to the DevTools server

defaultRole

The role to request automatically on connect. Null means no auto-request.

Constructors

Link copied to clipboard
constructor(serverUrl: String? = null, enabled: Boolean = true, autoConnect: Boolean = true, autoReconnect: Boolean = true, allowActionCapture: Boolean = true, allowStateCapture: Boolean = true, defaultRole: ClientRole? = null, allowRemoteRequests: Boolean = true)

Properties

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