# JDACommandManager (ACF (JDA) 0.5.1-SNAPSHOT API)
declaration: package: co.aikar.commands, class: JDACommandManager

Package co.aikar.commands

# Class JDACommandManager

java.lang.Object
co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>
co.aikar.commands.JDACommandManager

public class JDACommandManager extends co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>

## Field Summary

Fields
Modifier and Type
Field
Description
`protected Map<String,JDARootCommand>`
`commands`
`protected JDACommandCompletions`
`completions`
`protected JDACommandContexts`
`contexts`
`protected JDALocales`
`locales`

### Fields inherited from class co.aikar.commands.CommandManager

`conditions, defaultExceptionHandler, defaultFormatter, defaultHelpPerPage, dependencies, formatters, helpFormatter, issuersLocale, localeChangedCallbacks, replacements, rootCommands, supportedLanguages, usePerIssuerLocale`

## Constructor Summary

Constructors
Constructor
Description
`JDACommandManager(net.dv8tion.jda.api.JDA jda)`
`JDACommandManager(net.dv8tion.jda.api.JDA jda, JDAOptions options)`

## Method Summary

Modifier and Type
Method
Description
`co.aikar.commands.CommandExecutionContext`
`createCommandContext(co.aikar.commands.RegisteredCommand command, co.aikar.commands.CommandParameter parameter, co.aikar.commands.CommandIssuer sender, List<String> args, int i, Map<String,Object> passedArgs)`
`co.aikar.commands.CommandCompletionContext`
`createCompletionContext(co.aikar.commands.RegisteredCommand command, co.aikar.commands.CommandIssuer sender, String input, String config, String[] args)`
`co.aikar.commands.RootCommand`
`createRootCommand(String cmd)`
`long`
`getBotOwnerId()`
`co.aikar.commands.CommandCompletions<?>`
`getCommandCompletions()`
`co.aikar.commands.CommandContexts<?>`
`getCommandContexts()`
`JDACommandEvent`
`getCommandIssuer(Object issuer)`
`String`
`getCommandPrefix(co.aikar.commands.CommandIssuer issuer)`
`CommandConfigProvider`
`getConfigProvider()`
`CommandConfig`
`getDefaultConfig()`
`net.dv8tion.jda.api.JDA`
`getJDA()`
`co.aikar.commands.Locales`
`getLocales()`
`Logger`
`getLogger()`
`CommandPermissionResolver`
`getPermissionResolver()`
`Collection<co.aikar.commands.RootCommand>`
`getRegisteredRootCommands()`
`boolean`
`hasRegisteredCommands()`
`boolean`
`isCommandIssuer(Class<?> type)`
`void`
`log(co.aikar.commands.LogLevel level, String message, Throwable throwable)`
`static JDAOptions`
`options()`
`void`
`registerCommand(co.aikar.commands.BaseCommand command)`
`void`
`setConfigProvider(CommandConfigProvider configProvider)`
`void`
`setDefaultConfig(@NotNull CommandConfig defaultConfig)`
`void`
`setLogger(Logger logger)`
`void`
`setPermissionResolver(CommandPermissionResolver permissionResolver)`
`void`
`unregisterCommand(co.aikar.commands.BaseCommand command)`

### Methods inherited from class co.aikar.commands.CommandManager

`addSupportedLanguage, createConditionContext, createRegisteredCommand, enableUnstableAPI, formatMessage, generateCommandHelp, generateCommandHelp, generateCommandHelp, generateCommandHelp, getCommandConditions, getCommandReplacements, getCurrentCommandIssuer, getCurrentCommandManager, getCurrentCommandOperationContext, getDefaultExceptionHandler, getDefaultFormatter, getDefaultHelpPerPage, getFormat, getHelpFormatter, getIssuerLocale, getRootCommand, getSupportedLanguages, handleUncaughtException, hasPermission, hasPermission, isLoggingUnhandledExceptions, log, notifyLocaleChange, obtainRootCommand, onLocaleChange, registerDependency, registerDependency, sendMessage, sendMessage, setDefaultExceptionHandler, setDefaultExceptionHandler, setDefaultFormatter, setDefaultHelpPerPage, setFormat, setFormat, setFormat, setHelpFormatter, setIssuerLocale, usePerIssuerLocale, usingPerIssuerLocale`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### completions

protected JDACommandCompletions completions

### contexts

protected JDACommandContexts contexts

### locales

protected JDALocales locales

### commands

protected Map<String,JDARootCommand> commands

## Constructor Details

### JDACommandManager

public JDACommandManager (net.dv8tion.jda.api.JDA jda)

### JDACommandManager

public JDACommandManager (net.dv8tion.jda.api.JDA jda, JDAOptions options)

## Method Details

### options

public static JDAOptions options()

### getBotOwnerId

public long getBotOwnerId()

### getJDA

public net.dv8tion.jda.api.JDA getJDA()

### getLogger

public Logger getLogger()

### setLogger

public void setLogger (Logger logger)

### getDefaultConfig

public CommandConfig getDefaultConfig()

### setDefaultConfig

public void setDefaultConfig (@NotNull @NotNull CommandConfig defaultConfig)

### getConfigProvider

public CommandConfigProvider getConfigProvider()

### setConfigProvider

public void setConfigProvider (CommandConfigProvider configProvider)

### getPermissionResolver

public CommandPermissionResolver getPermissionResolver()

### setPermissionResolver

public void setPermissionResolver (CommandPermissionResolver permissionResolver)

### getCommandContexts

public co.aikar.commands.CommandContexts<?> getCommandContexts()

Specified by:
  `getCommandContexts` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### getCommandCompletions

public co.aikar.commands.CommandCompletions<?> getCommandCompletions()

Specified by:
  `getCommandCompletions` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### registerCommand

public void registerCommand (co.aikar.commands.BaseCommand command)

Specified by:
  `registerCommand` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### unregisterCommand

public void unregisterCommand (co.aikar.commands.BaseCommand command)

### hasRegisteredCommands

public boolean hasRegisteredCommands()

Specified by:
  `hasRegisteredCommands` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### isCommandIssuer

public boolean isCommandIssuer (Class<?> type)

Specified by:
  `isCommandIssuer` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### getCommandIssuer

public JDACommandEvent getCommandIssuer (Object issuer)

Specified by:
  `getCommandIssuer` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### createRootCommand

public co.aikar.commands.RootCommand createRootCommand (String cmd)

Specified by:
  `createRootCommand` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### getRegisteredRootCommands

public Collection<co.aikar.commands.RootCommand> getRegisteredRootCommands()

Specified by:
  `getRegisteredRootCommands` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### getLocales

public co.aikar.commands.Locales getLocales()

Specified by:
  `getLocales` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### createCommandContext

public co.aikar.commands.CommandExecutionContext createCommandContext (co.aikar.commands.RegisteredCommand command, co.aikar.commands.CommandParameter parameter, co.aikar.commands.CommandIssuer sender, List<String> args, int i, Map<String,Object> passedArgs)

Specified by:
  `createCommandContext` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### createCompletionContext

public co.aikar.commands.CommandCompletionContext createCompletionContext (co.aikar.commands.RegisteredCommand command, co.aikar.commands.CommandIssuer sender, String input, String config, String[] args)

Specified by:
  `createCompletionContext` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### log

public void log (co.aikar.commands.LogLevel level, String message, Throwable throwable)

Specified by:
  `log` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`

### getCommandPrefix

public String getCommandPrefix (co.aikar.commands.CommandIssuer issuer)

Overrides:
  `getCommandPrefix` in class `co.aikar.commands.CommandManager<net.dv8tion.jda.api.events.message.MessageReceivedEvent,JDACommandEvent,String,co.aikar.commands.MessageFormatter<String>,JDACommandExecutionContext,JDAConditionContext>`