# ProcessPid

Artifact: [androidx.test.uiautomator:uiautomator-shell](https://developer.android.com/jetpack/androidx/releases/test-uiautomator) [View Source](https://cs.android.com/search?q=file:androidx/test/shell/command/ProcessCommands.kt+class:androidx.test.shell.command.ProcessPid) Added in [2.4.1](https://developer.android.com/jetpack/androidx/releases/test-uiautomator#2.4.1)

*** ** * ** ***


```
public final class ProcessPid
```

<br />

*** ** * ** ***

Contains a process name and the process id associated with that name.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/test/shell/command/ProcessPid#ProcessPid(kotlin.String,kotlin.Int)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html processName, int pid)` |

| ### Public methods |
|---|---|
| `final int` | `https://developer.android.com/reference/androidx/test/shell/command/ProcessPid#getPid()()` The id of the process. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/test/shell/command/ProcessPid#getProcessName()()` The name of the process. |

## Public constructors

### ProcessPid

Added in [2.4.1](https://developer.android.com/jetpack/androidx/releases/test-uiautomator#2.4.1)

```
public ProcessPid(@NonNull String processName, int pid)
```

## Public methods

### getPid

Added in [2.4.1](https://developer.android.com/jetpack/androidx/releases/test-uiautomator#2.4.1)

```
public final int getPid()
```

The id of the process.

### getProcessName

Added in [2.4.1](https://developer.android.com/jetpack/androidx/releases/test-uiautomator#2.4.1)

```
public final @NonNull String getProcessName()
```

The name of the process.