CommonCore/testsrc/de/steamwar/command/dto/TestSWCommand.java

62 Zeilen
1.7 KiB
Java

2022-05-01 22:37:01 +02:00
/*
* This file is a part of the SteamWar software.
*
* Copyright (C) 2020 SteamWar.de-Serverteam
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
2022-04-22 10:16:25 +02:00
package de.steamwar.command.dto;
import de.steamwar.command.AbstractSWCommand;
import de.steamwar.command.CommandFrameworkException;
import java.util.function.Supplier;
public class TestSWCommand extends AbstractSWCommand<String> {
protected TestSWCommand(String command) {
super(String.class, command);
}
protected TestSWCommand(String command, String[] aliases) {
super(String.class, command, aliases);
}
@Override
protected void createAndSafeCommand(String command, String[] aliases) {
}
@Override
public void unregister() {
}
@Override
public void register() {
}
@Override
protected void commandSystemError(String sender, CommandFrameworkException e) {
System.out.println("CommandSystemError: " + e.getMessage());
2022-04-22 10:16:25 +02:00
}
@Override
protected void commandSystemWarning(Supplier<String> message) {
System.out.println("CommandSystemWarning: " + message.get());
2022-04-22 10:16:25 +02:00
}
}