Effective removal of annotated commands.
parent
38188d941d
commit
b505e79d2a
@ -1,47 +0,0 @@
|
|||||||
package net.pingex.dcf.commands;
|
|
||||||
|
|
||||||
import net.pingex.dcf.permissions.DefaultPermission;
|
|
||||||
import java.lang.annotation.ElementType;
|
|
||||||
import java.lang.annotation.Retention;
|
|
||||||
import java.lang.annotation.RetentionPolicy;
|
|
||||||
import java.lang.annotation.Target;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Indicated a method which is in fact a command
|
|
||||||
*/
|
|
||||||
@Retention(RetentionPolicy.RUNTIME)
|
|
||||||
@Target(ElementType.METHOD)
|
|
||||||
@Deprecated
|
|
||||||
public @interface AnnotatedCommand
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Main name of the command
|
|
||||||
*/
|
|
||||||
String name();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Command can also be called using the following list of aliases
|
|
||||||
*/
|
|
||||||
String[] aliases() default {};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Description of the command.
|
|
||||||
*/
|
|
||||||
String description() default Command.Defaults.DESCRIPTION;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Is the command enabled ? Can it be invoked ?
|
|
||||||
*/
|
|
||||||
boolean isEnabled() default Command.Defaults.IS_ENABLED;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Command usage help
|
|
||||||
*/
|
|
||||||
String usage() default Command.Defaults.USAGE;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Default permission, ie. when the permissions provider doesn't return anything.
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
DefaultPermission defaultPermission() default DefaultPermission.EVERYONE;
|
|
||||||
}
|
|
@ -1,17 +0,0 @@
|
|||||||
package net.pingex.dcf.commands;
|
|
||||||
|
|
||||||
import java.util.Set;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Indicates a plugin which can run commands (using annotated commands)
|
|
||||||
*/
|
|
||||||
@FunctionalInterface
|
|
||||||
@Deprecated
|
|
||||||
public interface IWithAnnotatedCommands
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Gives all annotated commands for this plugin.
|
|
||||||
* @return A set of objects which contains annotated commands.
|
|
||||||
*/
|
|
||||||
Set<Object> getAnnotatedObjects();
|
|
||||||
}
|
|
Reference in New Issue