Interface Command

All Known Implementing Classes:
AbstractCommand

public interface Command
Represents a single executable command in the shell.

A Command encapsulates everything about a command in one object: its name, aliases, description, execution logic, and completion support.

Example:

 Command echo = new AbstractCommand("echo") {
     @Override
     public Object execute(CommandSession session, String[] args) {
         session.out().println(String.join(" ", args));
         return null;
     }
 };
 
Since:
4.0
See Also: