Record Class BarricadeParticleOptions

java.lang.Object
java.lang.Record
net.modgarden.barricade.particle.BarricadeParticleOptions
All Implemented Interfaces:
net.minecraft.core.particles.ParticleOptions

public record BarricadeParticleOptions(BlockedDirections blockedDirections, net.minecraft.resources.Identifier icon, Optional<net.minecraft.core.BlockPos> origin) extends Record implements net.minecraft.core.particles.ParticleOptions
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    BarricadeParticleOptions(BlockedDirections blockedDirections, @Nullable net.minecraft.resources.Identifier icon, Optional<net.minecraft.core.BlockPos> origin)
    Creates an instance of a BarricadeParticleOptions record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the blockedDirections record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    @NotNull net.minecraft.core.particles.ParticleType<?>
     
    final int
    Returns a hash code value for this object.
    net.minecraft.resources.Identifier
    Returns the value of the icon record component.
    Optional<net.minecraft.core.BlockPos>
    Returns the value of the origin record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • BarricadeParticleOptions

      public BarricadeParticleOptions(BlockedDirections blockedDirections, @Nullable @Nullable net.minecraft.resources.Identifier icon, Optional<net.minecraft.core.BlockPos> origin)
      Creates an instance of a BarricadeParticleOptions record class.
      Parameters:
      blockedDirections - the value for the blockedDirections record component
      icon - the value for the icon record component
      origin - the value for the origin record component
  • Method Details

    • getType

      @NotNull public @NotNull net.minecraft.core.particles.ParticleType<?> getType()
      Specified by:
      getType in interface net.minecraft.core.particles.ParticleOptions
    • 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 Objects::equals(Object,Object).
      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.
    • blockedDirections

      public BlockedDirections blockedDirections()
      Returns the value of the blockedDirections record component.
      Returns:
      the value of the blockedDirections record component
    • icon

      public net.minecraft.resources.Identifier icon()
      Returns the value of the icon record component.
      Returns:
      the value of the icon record component
    • origin

      public Optional<net.minecraft.core.BlockPos> origin()
      Returns the value of the origin record component.
      Returns:
      the value of the origin record component