Class Request<T extends Request<T>>

java.lang.Object
net.minecraft.client.realms.Request<T>
Direct Known Subclasses:
Request.Delete, Request.Get, Request.Post, Request.Put

@Environment(CLIENT) public abstract class Request<T extends Request<T>> extends Object
Mappings:
Namespace Name
official dtb
intermediary net/minecraft/class_4346
named net/minecraft/client/realms/Request
  • Field Details

    • READ_TIMEOUT

      private static final int READ_TIMEOUT
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official d Ldtb;d:I
      intermediary field_32096 Lnet/minecraft/class_4346;field_32096:I
      named READ_TIMEOUT Lnet/minecraft/client/realms/Request;READ_TIMEOUT:I
    • CONNECT_TIMEOUT

      private static final int CONNECT_TIMEOUT
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official e Ldtb;e:I
      intermediary field_32097 Lnet/minecraft/class_4346;field_32097:I
      named CONNECT_TIMEOUT Lnet/minecraft/client/realms/Request;CONNECT_TIMEOUT:I
    • connection

      protected HttpURLConnection connection
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a:Ljava/net/HttpURLConnection;
      intermediary field_19596 Lnet/minecraft/class_4346;field_19596:Ljava/net/HttpURLConnection;
      named connection Lnet/minecraft/client/realms/Request;connection:Ljava/net/HttpURLConnection;
    • connected

      private boolean connected
      Mappings:
      Namespace Name Mixin selector
      official c Ldtb;c:Z
      intermediary field_19598 Lnet/minecraft/class_4346;field_19598:Z
      named connected Lnet/minecraft/client/realms/Request;connected:Z
    • url

      protected String url
      Mappings:
      Namespace Name Mixin selector
      official b Ldtb;b:Ljava/lang/String;
      intermediary field_19597 Lnet/minecraft/class_4346;field_19597:Ljava/lang/String;
      named url Lnet/minecraft/client/realms/Request;url:Ljava/lang/String;
  • Constructor Details

    • Request

      public Request(String url, int connectTimeout, int readTimeout)
      Mappings:
      Namespace Name Mixin selector
      official <init> Ldtb;<init>(Ljava/lang/String;II)V
      intermediary <init> Lnet/minecraft/class_4346;<init>(Ljava/lang/String;II)V
      named <init> Lnet/minecraft/client/realms/Request;<init>(Ljava/lang/String;II)V
  • Method Details

    • cookie

      public void cookie(String key, String value)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/lang/String;Ljava/lang/String;)V
      intermediary method_21042 Lnet/minecraft/class_4346;method_21042(Ljava/lang/String;Ljava/lang/String;)V
      named cookie Lnet/minecraft/client/realms/Request;cookie(Ljava/lang/String;Ljava/lang/String;)V
    • cookie

      public static void cookie(HttpURLConnection connection, String key, String value)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/net/HttpURLConnection;Ljava/lang/String;Ljava/lang/String;)V
      intermediary method_21046 Lnet/minecraft/class_4346;method_21046(Ljava/net/HttpURLConnection;Ljava/lang/String;Ljava/lang/String;)V
      named cookie Lnet/minecraft/client/realms/Request;cookie(Ljava/net/HttpURLConnection;Ljava/lang/String;Ljava/lang/String;)V
    • withHeader

      public T withHeader(String name, String value)
      Mappings:
      Namespace Name Mixin selector
      official b Ldtb;b(Ljava/lang/String;Ljava/lang/String;)Ldtb;
      intermediary method_35685 Lnet/minecraft/class_4346;method_35685(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/class_4346;
      named withHeader Lnet/minecraft/client/realms/Request;withHeader(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/client/realms/Request;
    • getRetryAfterHeader

      public int getRetryAfterHeader()
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a()I
      intermediary method_21038 Lnet/minecraft/class_4346;method_21038()I
      named getRetryAfterHeader Lnet/minecraft/client/realms/Request;getRetryAfterHeader()I
    • getRetryAfterHeader

      public static int getRetryAfterHeader(HttpURLConnection connection)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/net/HttpURLConnection;)I
      intermediary method_21044 Lnet/minecraft/class_4346;method_21044(Ljava/net/HttpURLConnection;)I
      named getRetryAfterHeader Lnet/minecraft/client/realms/Request;getRetryAfterHeader(Ljava/net/HttpURLConnection;)I
    • responseCode

      public int responseCode()
      Mappings:
      Namespace Name Mixin selector
      official b Ldtb;b()I
      intermediary method_21047 Lnet/minecraft/class_4346;method_21047()I
      named responseCode Lnet/minecraft/client/realms/Request;responseCode()I
    • text

      public String text()
      Mappings:
      Namespace Name Mixin selector
      official c Ldtb;c()Ljava/lang/String;
      intermediary method_21051 Lnet/minecraft/class_4346;method_21051()Ljava/lang/String;
      named text Lnet/minecraft/client/realms/Request;text()Ljava/lang/String;
    • read

      private String read(@Nullable @Nullable InputStream in) throws IOException
      Throws:
      IOException
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/io/InputStream;)Ljava/lang/String;
      intermediary method_21039 Lnet/minecraft/class_4346;method_21039(Ljava/io/InputStream;)Ljava/lang/String;
      named read Lnet/minecraft/client/realms/Request;read(Ljava/io/InputStream;)Ljava/lang/String;
    • dispose

      private void dispose()
      Mappings:
      Namespace Name Mixin selector
      official f Ldtb;f()V
      intermediary method_21056 Lnet/minecraft/class_4346;method_21056()V
      named dispose Lnet/minecraft/client/realms/Request;dispose()V
    • connect

      protected T connect()
      Mappings:
      Namespace Name Mixin selector
      official d Ldtb;d()Ldtb;
      intermediary method_21054 Lnet/minecraft/class_4346;method_21054()Lnet/minecraft/class_4346;
      named connect Lnet/minecraft/client/realms/Request;connect()Lnet/minecraft/client/realms/Request;
    • doConnect

      protected abstract T doConnect()
      Mappings:
      Namespace Name Mixin selector
      official e Ldtb;e()Ldtb;
      intermediary method_21055 Lnet/minecraft/class_4346;method_21055()Lnet/minecraft/class_4346;
      named doConnect Lnet/minecraft/client/realms/Request;doConnect()Lnet/minecraft/client/realms/Request;
    • get

      public static Request<?> get(String url)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/lang/String;)Ldtb;
      intermediary method_21040 Lnet/minecraft/class_4346;method_21040(Ljava/lang/String;)Lnet/minecraft/class_4346;
      named get Lnet/minecraft/client/realms/Request;get(Ljava/lang/String;)Lnet/minecraft/client/realms/Request;
    • get

      public static Request<?> get(String url, int connectTimeoutMillis, int readTimeoutMillis)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/lang/String;II)Ldtb;
      intermediary method_21041 Lnet/minecraft/class_4346;method_21041(Ljava/lang/String;II)Lnet/minecraft/class_4346;
      named get Lnet/minecraft/client/realms/Request;get(Ljava/lang/String;II)Lnet/minecraft/client/realms/Request;
    • post

      public static Request<?> post(String uri, String content)
      Mappings:
      Namespace Name Mixin selector
      official c Ldtb;c(Ljava/lang/String;Ljava/lang/String;)Ldtb;
      intermediary method_21049 Lnet/minecraft/class_4346;method_21049(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/class_4346;
      named post Lnet/minecraft/client/realms/Request;post(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/client/realms/Request;
    • post

      public static Request<?> post(String uri, String content, int connectTimeoutMillis, int readTimeoutMillis)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/lang/String;Ljava/lang/String;II)Ldtb;
      intermediary method_21043 Lnet/minecraft/class_4346;method_21043(Ljava/lang/String;Ljava/lang/String;II)Lnet/minecraft/class_4346;
      named post Lnet/minecraft/client/realms/Request;post(Ljava/lang/String;Ljava/lang/String;II)Lnet/minecraft/client/realms/Request;
    • delete

      public static Request<?> delete(String url)
      Mappings:
      Namespace Name Mixin selector
      official b Ldtb;b(Ljava/lang/String;)Ldtb;
      intermediary method_21048 Lnet/minecraft/class_4346;method_21048(Ljava/lang/String;)Lnet/minecraft/class_4346;
      named delete Lnet/minecraft/client/realms/Request;delete(Ljava/lang/String;)Lnet/minecraft/client/realms/Request;
    • put

      public static Request<?> put(String url, String content)
      Mappings:
      Namespace Name Mixin selector
      official d Ldtb;d(Ljava/lang/String;Ljava/lang/String;)Ldtb;
      intermediary method_21053 Lnet/minecraft/class_4346;method_21053(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/class_4346;
      named put Lnet/minecraft/client/realms/Request;put(Ljava/lang/String;Ljava/lang/String;)Lnet/minecraft/client/realms/Request;
    • put

      public static Request<?> put(String url, String content, int connectTimeoutMillis, int readTimeoutMillis)
      Mappings:
      Namespace Name Mixin selector
      official b Ldtb;b(Ljava/lang/String;Ljava/lang/String;II)Ldtb;
      intermediary method_21050 Lnet/minecraft/class_4346;method_21050(Ljava/lang/String;Ljava/lang/String;II)Lnet/minecraft/class_4346;
      named put Lnet/minecraft/client/realms/Request;put(Ljava/lang/String;Ljava/lang/String;II)Lnet/minecraft/client/realms/Request;
    • getHeader

      public String getHeader(String header)
      Mappings:
      Namespace Name Mixin selector
      official c Ldtb;c(Ljava/lang/String;)Ljava/lang/String;
      intermediary method_21052 Lnet/minecraft/class_4346;method_21052(Ljava/lang/String;)Ljava/lang/String;
      named getHeader Lnet/minecraft/client/realms/Request;getHeader(Ljava/lang/String;)Ljava/lang/String;
    • getHeader

      public static String getHeader(HttpURLConnection connection, String header)
      Mappings:
      Namespace Name Mixin selector
      official a Ldtb;a(Ljava/net/HttpURLConnection;Ljava/lang/String;)Ljava/lang/String;
      intermediary method_21045 Lnet/minecraft/class_4346;method_21045(Ljava/net/HttpURLConnection;Ljava/lang/String;)Ljava/lang/String;
      named getHeader Lnet/minecraft/client/realms/Request;getHeader(Ljava/net/HttpURLConnection;Ljava/lang/String;)Ljava/lang/String;