Class JsonRPCUtils

java.lang.Object
net.minecraft.server.jsonrpc.JsonRPCUtils

public class JsonRPCUtils extends Object
  • Field Details

  • Constructor Details

    • JsonRPCUtils

      public JsonRPCUtils()
  • Method Details

    • createSuccessResult

      public static com.google.gson.JsonObject createSuccessResult(com.google.gson.JsonElement id, com.google.gson.JsonElement result)
    • createRequest

      public static com.google.gson.JsonObject createRequest(@Nullable Integer id, Identifier method, List<com.google.gson.JsonElement> params)
    • createError

      public static com.google.gson.JsonObject createError(com.google.gson.JsonElement id, String message, int errorCode, @Nullable String data)
    • getRequestId

      public static @Nullable com.google.gson.JsonElement getRequestId(com.google.gson.JsonObject jsonObject)
    • getMethodName

      public static @Nullable String getMethodName(com.google.gson.JsonObject jsonObject)
    • getParams

      public static @Nullable com.google.gson.JsonElement getParams(com.google.gson.JsonObject jsonObject)
    • getResult

      public static @Nullable com.google.gson.JsonElement getResult(com.google.gson.JsonObject jsonObject)
    • getError

      public static @Nullable com.google.gson.JsonObject getError(com.google.gson.JsonObject jsonObject)