public static class Shell


Allows to execute commands. This class builds on top of ShellProcess and abstracts the shell streams to focus on the output of a single command execution. A ShellProcess is created for each executed command, using a ShellServer that can be reset by Shell.setShellServer.

Summary

Nested types

public final class Shell.CommandOutput

The output of a shell command executed via Shell.command.

Public fields

static @NonNull Shell

Public methods

final @NonNull ApplicationCommands
application(@NonNull String packageName)

Commands for application.

final @NonNull Shell.CommandOutput

Executes a given command and returns the ongoing CommandOutput.

final @NonNull PermissionCommands
permission(@NonNull String packageName)

Commands for permissions.

final @NonNull ProcessCommands

Commands for processes.

final @NonNull RecorderCommands

Commands for screen recorder.

final @NonNull ScreenCommands

Commands for screen.