CommandAPI 9.3.0
An API for the command UI introduced in Minecraft 1.13
dev.jorel.commandapi.Converter Class Reference

'Simple' conversion of Plugin commands More...

Static Public Member Functions

static void convert (JavaPlugin plugin)
 Convert all commands stated in Plugin's plugin.yml file into CommandAPI-compatible commands. More...
 
static void convert (JavaPlugin plugin, String cmdName)
 Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands. More...
 
static void convert (JavaPlugin plugin, String cmdName, Argument<?>... arguments)
 Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands. More...
 
static void convert (JavaPlugin plugin, String cmdName, List< Argument<?> > arguments)
 Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands. More...
 
static void convert (String cmdName)
 Convert the provided command name into a CommandAPI-compatible command. More...
 
static void convert (String cmdName, List< Argument<?> > arguments)
 Convert the provided command name with its list of arguments into a CommandAPI-compatible command. More...
 

Detailed Description

'Simple' conversion of Plugin commands

Member Function Documentation

◆ convert() [1/6]

static void dev.jorel.commandapi.Converter.convert ( JavaPlugin  plugin)
static

Convert all commands stated in Plugin's plugin.yml file into CommandAPI-compatible commands.

Parameters
pluginThe plugin which commands are to be converted

◆ convert() [2/6]

static void dev.jorel.commandapi.Converter.convert ( JavaPlugin  plugin,
String  cmdName 
)
static

Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands.

Parameters
pluginThe plugin where the command is registered
cmdNameThe command to convert

◆ convert() [3/6]

static void dev.jorel.commandapi.Converter.convert ( JavaPlugin  plugin,
String  cmdName,
Argument<?>...  arguments 
)
static

Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands.

Parameters
pluginThe plugin where the command is registered
cmdNameThe command to convert
argumentsThe arguments that should be used to parse this command

◆ convert() [4/6]

static void dev.jorel.commandapi.Converter.convert ( JavaPlugin  plugin,
String  cmdName,
List< Argument<?> >  arguments 
)
static

Convert a command stated in Plugin's plugin.yml file into CommandAPI-compatible commands.

Parameters
pluginThe plugin where the command is registered
cmdNameThe command to convert
argumentsThe arguments that should be used to parse this command

◆ convert() [5/6]

static void dev.jorel.commandapi.Converter.convert ( String  cmdName)
static

Convert the provided command name into a CommandAPI-compatible command.

Parameters
cmdNameThe name of the command (without the leading /). For commands such as //set in WorldEdit, this parameter should be "/set"

◆ convert() [6/6]

static void dev.jorel.commandapi.Converter.convert ( String  cmdName,
List< Argument<?> >  arguments 
)
static

Convert the provided command name with its list of arguments into a CommandAPI-compatible command.

Parameters
cmdNameThe name of the command (without the leading /). For commands such as //set in WorldEdit, this parameter should be "/set"
argumentsThe arguments that should be used to parse this command