public final class IdlingPolicy


Allows users to control idling idleTimeouts in Espresso.

Summary

Public fields

final boolean
final long
final boolean

Public methods

boolean
long

The amount of time the policy allows a resource to be non-idle.

TimeUnit

The unit for getIdleTimeout.

boolean

When true, timeouts should occur even if a debugger is attached to the VM.

void
handleTimeout(List<String> busyResources, String message)

Invoked when the idle idleTimeout has been exceeded.

Public fields

disableOnTimeout

public final boolean disableOnTimeout

idleTimeout

public final long idleTimeout

timeoutIfDebuggerAttached

public final boolean timeoutIfDebuggerAttached

Public methods

getDisableOnTimeout

public boolean getDisableOnTimeout()

getIdleTimeout

public long getIdleTimeout()

The amount of time the policy allows a resource to be non-idle.

getIdleTimeoutUnit

public TimeUnit getIdleTimeoutUnit()

The unit for getIdleTimeout.

getTimeoutIfDebuggerAttached

public boolean getTimeoutIfDebuggerAttached()

When true, timeouts should occur even if a debugger is attached to the VM. When false, they should be suppressed.

handleTimeout

public void handleTimeout(List<String> busyResources, String message)

Invoked when the idle idleTimeout has been exceeded.

Parameters
List<String> busyResources

the resources that are not idle.

String message

an additional message to include in an exception.