Record Class AbuseReportSender.Services
java.lang.Object
java.lang.Record
net.minecraft.client.multiplayer.chat.report.AbuseReportSender.Services
- All Implemented Interfaces:
AbuseReportSender
- Enclosing interface:
AbuseReportSender
public static record AbuseReportSender.Services(ReportEnvironment environment, com.mojang.authlib.minecraft.UserApiService userApiService)
extends Record
implements AbuseReportSender
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.client.multiplayer.chat.report.AbuseReportSender
AbuseReportSender.SendException, AbuseReportSender.Services
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ReportEnvironment
The field for theenvironment
record component.private static final Component
private static final Component
private static final Component
private final com.mojang.authlib.minecraft.UserApiService
The field for theuserApiService
record component. -
Constructor Summary
ConstructorDescriptionServices
(ReportEnvironment environment, com.mojang.authlib.minecraft.UserApiService userApiService) Creates an instance of aServices
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theenvironment
record component.final boolean
Indicates whether some other object is "equal to" this one.private Component
getErrorDescription
(com.mojang.authlib.exceptions.MinecraftClientException p_240068_) private Component
getHttpErrorDescription
(com.mojang.authlib.exceptions.MinecraftClientHttpException p_239705_) final int
hashCode()
Returns a hash code value for this object.boolean
com.mojang.authlib.minecraft.report.AbuseReportLimits
CompletableFuture
<com.mojang.datafixers.util.Unit> send
(UUID p_239470_, ReportType p_299858_, com.mojang.authlib.minecraft.report.AbuseReport p_239471_) final String
toString()
Returns a string representation of this record class.com.mojang.authlib.minecraft.UserApiService
Returns the value of theuserApiService
record component.
-
Field Details
-
environment
The field for theenvironment
record component. -
userApiService
private final com.mojang.authlib.minecraft.UserApiService userApiServiceThe field for theuserApiService
record component. -
SERVICE_UNAVAILABLE_TEXT
-
HTTP_ERROR_TEXT
-
JSON_ERROR_TEXT
-
-
Constructor Details
-
Services
public Services(ReportEnvironment environment, com.mojang.authlib.minecraft.UserApiService userApiService) Creates an instance of aServices
record class.- Parameters:
environment
- the value for theenvironment
record componentuserApiService
- the value for theuserApiService
record component
-
-
Method Details
-
send
public CompletableFuture<com.mojang.datafixers.util.Unit> send(UUID p_239470_, ReportType p_299858_, com.mojang.authlib.minecraft.report.AbuseReport p_239471_) - Specified by:
send
in interfaceAbuseReportSender
-
isEnabled
public boolean isEnabled()- Specified by:
isEnabled
in interfaceAbuseReportSender
-
getHttpErrorDescription
private Component getHttpErrorDescription(com.mojang.authlib.exceptions.MinecraftClientHttpException p_239705_) -
getErrorDescription
private Component getErrorDescription(com.mojang.authlib.exceptions.MinecraftClientException p_240068_) -
reportLimits
public com.mojang.authlib.minecraft.report.AbuseReportLimits reportLimits()- Specified by:
reportLimits
in interfaceAbuseReportSender
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
environment
Returns the value of theenvironment
record component.- Returns:
- the value of the
environment
record component
-
userApiService
public com.mojang.authlib.minecraft.UserApiService userApiService()Returns the value of theuserApiService
record component.- Returns:
- the value of the
userApiService
record component
-