Class KJSHTTPRequest

java.lang.Object
dev.latvian.apps.tinyserver.http.HTTPRequest
dev.latvian.mods.kubejs.web.KJSHTTPRequest

public class KJSHTTPRequest extends dev.latvian.apps.tinyserver.http.HTTPRequest
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final net.minecraft.util.thread.BlockableEventLoop<?>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    KJSHTTPRequest(net.minecraft.util.thread.BlockableEventLoop<?> eventLoop)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.core.component.DataComponentPatch
    components(com.mojang.serialization.DynamicOps<net.minecraft.nbt.Tag> ops)
     
    dev.latvian.apps.tinyserver.http.response.HTTPResponse
    handleResponse(dev.latvian.apps.tinyserver.http.response.HTTPPayload payload, dev.latvian.apps.tinyserver.http.response.HTTPResponse response, @Nullable Throwable error)
     
    @Nullable net.minecraft.resources.ResourceLocation
    id()
     
    net.minecraft.resources.ResourceLocation
    id(String ns, String path)
     
     
    void
     
    <T> T
     

    Methods inherited from class dev.latvian.apps.tinyserver.http.HTTPRequest

    acceptedEncodings, afterInit, afterResponse, bodyBuffer, bodyList, connection, cookie, cookies, country, createPreResponse, formData, formData, fullPath, gitHubEvent, gitHubSignature, header, headers, init, ip, ipv6, mainBody, method, path, pathParts, preInit, query, query, queryString, server, startTime, userAgent, variable, variables

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • eventLoop

      public final net.minecraft.util.thread.BlockableEventLoop<?> eventLoop
  • Constructor Details

    • KJSHTTPRequest

      public KJSHTTPRequest(net.minecraft.util.thread.BlockableEventLoop<?> eventLoop)
  • Method Details

    • registries

      public RegistryAccessContainer registries()
    • runInMainThread

      public void runInMainThread(Runnable task)
    • supplyInMainThread

      public <T> T supplyInMainThread(Supplier<T> task)
    • id

      public net.minecraft.resources.ResourceLocation id(String ns, String path)
    • id

      @Nullable public @Nullable net.minecraft.resources.ResourceLocation id()
    • components

      public net.minecraft.core.component.DataComponentPatch components(com.mojang.serialization.DynamicOps<net.minecraft.nbt.Tag> ops) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • handleResponse

      public dev.latvian.apps.tinyserver.http.response.HTTPResponse handleResponse(dev.latvian.apps.tinyserver.http.response.HTTPPayload payload, dev.latvian.apps.tinyserver.http.response.HTTPResponse response, @Nullable @Nullable Throwable error)
      Overrides:
      handleResponse in class dev.latvian.apps.tinyserver.http.HTTPRequest