# RemoteInteractionRegistry

Artifact: [androidx.test.espresso:espresso-core](https://developer.android.com/jetpack/androidx/releases/test-espresso) [View Source](https://cs.android.com/search?q=file:androidx/test/espresso/remote/RemoteInteractionRegistry.java+class:androidx.test.espresso.remote.RemoteInteractionRegistry)

*** ** * ** ***


```
public class RemoteInteractionRegistry
```

<br />

*** ** * ** ***

An exposed registry instance to make it easy for callers to get a hold of Remote Interaction

## Summary

| ### Public methods |
|---|---|
| `static https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction` | `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteractionRegistry#getInstance()()` Returns the `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction` |
| `static void` | `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteractionRegistry#registerInstance(androidx.test.espresso.remote.RemoteInteraction)(https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction remoteInteraction)` Stores the remote interaction in the registry. |

## Public methods

### getInstance

```
public static RemoteInteraction getInstance()
```

Returns the `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction`

This remote interaction is not guaranteed to be present under all instrumentations.

| Returns |
|---|---|
| `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction` | RemoteInteraction the remote interaction for this application. If no remote interaction has been registered a `https://developer.android.com/reference/androidx/test/espresso/remote/NoopRemoteInteraction` will be returned. |

### registerInstance

```
public static void registerInstance(RemoteInteraction remoteInteraction)
```

Stores the remote interaction in the registry.

This is a global registry - so be aware of the impact of calling this method!

| Parameters |
|---|---|
| `https://developer.android.com/reference/androidx/test/espresso/remote/RemoteInteraction remoteInteraction` | the remote interaction for this application. \<@code\>Nullde-registers any existing monitor. |