public static class CommandCatalog.DefaultCommandCatalog extends Object implements CommandCatalog
CommandCatalog
.CommandCatalog.DefaultCommandCatalog
Modifier and Type | Method and Description |
---|---|
Map<String,CommandRegistration> |
getRegistrations()
Gets all
CommandRegistration s mapped with their names. |
void |
register(CommandRegistration... registration)
Register a
CommandRegistration . |
void |
unregister(CommandRegistration... registration)
Unregister a
CommandRegistration . |
void |
unregister(String... commandName)
Unregister a
CommandRegistration by its command name. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
of, of
public void register(CommandRegistration... registration)
CommandCatalog
CommandRegistration
.register
in interface CommandCatalog
registration
- the command registrationpublic void unregister(CommandRegistration... registration)
CommandCatalog
CommandRegistration
.unregister
in interface CommandCatalog
registration
- the command registrationpublic void unregister(String... commandName)
CommandCatalog
CommandRegistration
by its command name.unregister
in interface CommandCatalog
commandName
- the command namepublic Map<String,CommandRegistration> getRegistrations()
CommandCatalog
CommandRegistration
s mapped with their names.
Returned map is a copy and cannot be used to register new commands.getRegistrations
in interface CommandCatalog
Copyright © 2024. All rights reserved.