public interface SshCommandFactory
SshCommand
instances to run them.Modifier and Type | Method and Description |
---|---|
Optional<SshCommand> |
create(SshCommandContext context) |
boolean |
supports(String command) |
@Nonnull Optional<SshCommand> create(@Nonnull SshCommandContext context)
context
- context describing the command, which can be used by the factory implementations to determine
whether it supports the command or notSshCommand
implementing the described command, which will be empty
if the command is not supported
boolean supports(@Nonnull String command)
command
- the command from the remote client (e.g. "git-upload-pack path/to/repository")true
if this factory can create an SshCommand
for the provided command;
otherwise, false
to try other factoriesCopyright © 2024 Atlassian. All rights reserved.