Record Class RestrictionsMessage
java.lang.Object
java.lang.Record
fr.ghostrider584.axiom.network.packet.server.RestrictionsMessage
- All Implemented Interfaces:
net.minestom.server.network.packet.server.SendablePacket,net.minestom.server.network.packet.server.ServerPacket,net.minestom.server.network.packet.server.ServerPacket.Play
public record RestrictionsMessage(EnumSet<AxiomPermission> allowedPermissions, EnumSet<AxiomPermission> deniedPermissions, int infiniteReachLimit, Set<RestrictionsMessage.PlotBox> bounds)
extends Record
implements net.minestom.server.network.packet.server.ServerPacket.Play
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minestom.server.network.packet.server.ServerPacket
net.minestom.server.network.packet.server.ServerPacket.ComponentHolding, net.minestom.server.network.packet.server.ServerPacket.Configuration, net.minestom.server.network.packet.server.ServerPacket.Login, net.minestom.server.network.packet.server.ServerPacket.Play, net.minestom.server.network.packet.server.ServerPacket.Status -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final net.minestom.server.network.NetworkBuffer.Type<RestrictionsMessage> -
Constructor Summary
ConstructorsConstructorDescriptionRestrictionsMessage(EnumSet<AxiomPermission> allowedPermissions, EnumSet<AxiomPermission> deniedPermissions, int infiniteReachLimit, Set<RestrictionsMessage.PlotBox> bounds) Creates an instance of aRestrictionsMessagerecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theallowedPermissionsrecord component.bounds()Returns the value of theboundsrecord component.Returns the value of thedeniedPermissionsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of theinfiniteReachLimitrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
TYPE
-
-
Constructor Details
-
RestrictionsMessage
public RestrictionsMessage(EnumSet<AxiomPermission> allowedPermissions, EnumSet<AxiomPermission> deniedPermissions, int infiniteReachLimit, Set<RestrictionsMessage.PlotBox> bounds) Creates an instance of aRestrictionsMessagerecord class.- Parameters:
allowedPermissions- the value for theallowedPermissionsrecord componentdeniedPermissions- the value for thedeniedPermissionsrecord componentinfiniteReachLimit- the value for theinfiniteReachLimitrecord componentbounds- the value for theboundsrecord component
-
RestrictionsMessage
public RestrictionsMessage()
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
allowedPermissions
Returns the value of theallowedPermissionsrecord component.- Returns:
- the value of the
allowedPermissionsrecord component
-
deniedPermissions
Returns the value of thedeniedPermissionsrecord component.- Returns:
- the value of the
deniedPermissionsrecord component
-
infiniteReachLimit
public int infiniteReachLimit()Returns the value of theinfiniteReachLimitrecord component.- Returns:
- the value of the
infiniteReachLimitrecord component
-
bounds
Returns the value of theboundsrecord component.- Returns:
- the value of the
boundsrecord component
-