Record Class PlatformCapabilities

java.lang.Object
java.lang.Record
devs.beer.nativepackets.api.PlatformCapabilities
Record Components:
paper - Paper API marker
folia - Folia regionized runtime
regionScheduler - region scheduler API
entityScheduler - entity scheduler API
globalRegionScheduler - global-region scheduler API
asyncScheduler - async scheduler API

public record PlatformCapabilities(boolean paper, boolean folia, boolean regionScheduler, boolean entityScheduler, boolean globalRegionScheduler, boolean asyncScheduler) extends Record
Startup-verified optional platform capabilities.
  • Constructor Details

    • PlatformCapabilities

      public PlatformCapabilities(boolean paper, boolean folia, boolean regionScheduler, boolean entityScheduler, boolean globalRegionScheduler, boolean asyncScheduler)
      Creates an instance of a PlatformCapabilities record class.
      Parameters:
      paper - the value for the paper record component
      folia - the value for the folia record component
      regionScheduler - the value for the regionScheduler record component
      entityScheduler - the value for the entityScheduler record component
      globalRegionScheduler - the value for the globalRegionScheduler record component
      asyncScheduler - the value for the asyncScheduler record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • paper

      public boolean paper()
      Returns the value of the paper record component.
      Returns:
      the value of the paper record component
    • folia

      public boolean folia()
      Returns the value of the folia record component.
      Returns:
      the value of the folia record component
    • regionScheduler

      public boolean regionScheduler()
      Returns the value of the regionScheduler record component.
      Returns:
      the value of the regionScheduler record component
    • entityScheduler

      public boolean entityScheduler()
      Returns the value of the entityScheduler record component.
      Returns:
      the value of the entityScheduler record component
    • globalRegionScheduler

      public boolean globalRegionScheduler()
      Returns the value of the globalRegionScheduler record component.
      Returns:
      the value of the globalRegionScheduler record component
    • asyncScheduler

      public boolean asyncScheduler()
      Returns the value of the asyncScheduler record component.
      Returns:
      the value of the asyncScheduler record component