mirror of
https://github.com/Sollace/Unicopia.git
synced 2025-03-25 12:31:31 +01:00
16 lines
381 B
Java
16 lines
381 B
Java
package com.minelittlepony.unicopia.command;
|
|
|
|
import net.minecraft.util.StringIdentifiable;
|
|
|
|
public interface CommandArgumentEnum<T extends Enum<T> & CommandArgumentEnum<T>> extends StringIdentifiable {
|
|
|
|
@SuppressWarnings("unchecked")
|
|
default T asSelf() {
|
|
return (T)this;
|
|
}
|
|
|
|
@Override
|
|
default String asString() {
|
|
return asSelf().name();
|
|
}
|
|
}
|