mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-10 04:38:35 +00:00
Minor upstream merge
This commit is contained in:
@ -21,6 +21,8 @@ package com.sk89q.worldedit.extension.platform;
|
||||
|
||||
import com.sk89q.worldedit.LocalConfiguration;
|
||||
import com.sk89q.worldedit.entity.Player;
|
||||
import com.sk89q.worldedit.internal.util.NonAbstractForCompatibility;
|
||||
import com.sk89q.worldedit.registry.Keyed;
|
||||
import com.sk89q.worldedit.util.SideEffect;
|
||||
import com.sk89q.worldedit.util.io.ResourceLoader;
|
||||
import com.sk89q.worldedit.world.DataFixer;
|
||||
@ -29,6 +31,7 @@ import com.sk89q.worldedit.world.registry.Registries;
|
||||
import org.enginehub.piston.CommandManager;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import javax.annotation.Nullable;
|
||||
@ -39,7 +42,7 @@ import javax.annotation.Nullable;
|
||||
* <p>It is strongly recommended that implementations extend from
|
||||
* {@link AbstractPlatform}.</p>
|
||||
*/
|
||||
public interface Platform {
|
||||
public interface Platform extends Keyed {
|
||||
|
||||
/**
|
||||
* Return the resource loader.
|
||||
@ -176,6 +179,18 @@ public interface Platform {
|
||||
*/
|
||||
String getPlatformVersion();
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
* @return an id
|
||||
* @apiNote This must be overridden by new subclasses. See {@link NonAbstractForCompatibility}
|
||||
* for details
|
||||
*/
|
||||
@NonAbstractForCompatibility(delegateName = "getPlatformName", delegateParams = {})
|
||||
@Override
|
||||
default String getId() {
|
||||
return "legacy:" + getPlatformName().toLowerCase(Locale.ROOT).replaceAll("[^a-z_.-]", "_");
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a map of advertised capabilities of this platform, where each key
|
||||
* in the given map is a supported capability and the respective value
|
||||
|
Reference in New Issue
Block a user