public abstract class CommandModule
extends com.google.gerrit.lifecycle.LifecycleModule
Modifier and Type | Field and Description |
---|---|
protected boolean |
slaveMode |
Constructor and Description |
---|
CommandModule() |
Modifier and Type | Method and Description |
---|---|
protected void |
alias(CommandName parent,
java.lang.String name,
java.lang.Class<? extends BaseCommand> clazz)
Alias one command to another.
|
protected void |
alias(java.lang.String from,
java.lang.String to)
Alias one command to another.
|
protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> |
command(CommandName name)
Configure a command to be invoked by name.
|
protected void |
command(CommandName parent,
java.lang.Class<? extends BaseCommand> clazz)
Configure a command to be invoked by name.
|
protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> |
command(CommandName parent,
java.lang.String name)
Configure a command to be invoked by name.
|
protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> |
command(java.lang.String name)
Configure a command to be invoked by name.
|
factory
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindListener, bindListener, bindScope, configure, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestStaticInjection, requireBinding, requireBinding
protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> command(java.lang.String name)
name
- the name of the command the client will provide in order to call the command.Command
object.protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> command(CommandName name)
name
- the name of the command the client will provide in order to call the command.Command
object.protected com.google.inject.binder.LinkedBindingBuilder<org.apache.sshd.server.command.Command> command(CommandName parent, java.lang.String name)
parent
- context of the parent command, that this command is a subcommand of.name
- the name of the command the client will provide in order to call the command.Command
object.protected void command(CommandName parent, java.lang.Class<? extends BaseCommand> clazz)
parent
- context of the parent command, that this command is a subcommand of.clazz
- class of the command with CommandMetaData
annotation to retrieve the name
and the description fromprotected void alias(CommandName parent, java.lang.String name, java.lang.Class<? extends BaseCommand> clazz)
parent
- context of the parent command, that this command is a subcommand of.name
- the name of the command the client will provide in order to call the command.clazz
- class of the command with CommandMetaData
annotation to retrieve the
description fromprotected void alias(java.lang.String from, java.lang.String to)
from
- the new command name that when called will actually delegate to to
's
implementation.to
- name of an already registered command that will perform the action when from
is invoked by a client.