Class CliCommandGroup<GlobalFlagsT extends CliFlags>
- java.lang.Object
-
- org.apache.bookkeeper.tools.framework.CliCommand<GlobalFlagsT,GlobalFlagsT>
-
- org.apache.bookkeeper.tools.framework.CliCommandGroup<GlobalFlagsT>
-
- All Implemented Interfaces:
Command<GlobalFlagsT>
,CommandGroup<GlobalFlagsT>
public abstract class CliCommandGroup<GlobalFlagsT extends CliFlags> extends CliCommand<GlobalFlagsT,GlobalFlagsT> implements CommandGroup<GlobalFlagsT>
A command group that group commands together. They share same global flags.
-
-
Field Summary
-
Fields inherited from class org.apache.bookkeeper.tools.framework.CliCommand
spec
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
CliCommandGroup(CliSpec<GlobalFlagsT> spec)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Boolean
apply(GlobalFlagsT globalFlags, java.lang.String[] args)
Process the command.void
usage()
Print the help information.-
Methods inherited from class org.apache.bookkeeper.tools.framework.CliCommand
category, description, getUsage, name, path, setParent
-
-
-
-
Constructor Detail
-
CliCommandGroup
protected CliCommandGroup(CliSpec<GlobalFlagsT> spec)
-
-
Method Detail
-
apply
public java.lang.Boolean apply(GlobalFlagsT globalFlags, java.lang.String[] args)
Description copied from interface:Command
Process the command.- Specified by:
apply
in interfaceCommand<GlobalFlagsT extends CliFlags>
- Overrides:
apply
in classCliCommand<GlobalFlagsT extends CliFlags,GlobalFlagsT extends CliFlags>
args
- command args- Returns:
- true if successfully apply the args, otherwise false
-
usage
public void usage()
Description copied from interface:Command
Print the help information.- Specified by:
usage
in interfaceCommand<GlobalFlagsT extends CliFlags>
- Overrides:
usage
in classCliCommand<GlobalFlagsT extends CliFlags,GlobalFlagsT extends CliFlags>
-
-