Record Class BlockSetType
java.lang.Object
java.lang.Record
net.minecraft.world.level.block.state.properties.BlockSetType
public record BlockSetType(String name, boolean canOpenByHand, SoundType soundType, SoundEvent doorClose, SoundEvent doorOpen, SoundEvent trapdoorClose, SoundEvent trapdoorOpen, SoundEvent pressurePlateClickOff, SoundEvent pressurePlateClickOn, SoundEvent buttonClickOff, SoundEvent buttonClickOn)
extends Record
-
Field Summary
Modifier and TypeFieldDescriptionstatic final BlockSetType
static final BlockSetType
static final BlockSetType
private final SoundEvent
The field for thebuttonClickOff
record component.private final SoundEvent
The field for thebuttonClickOn
record component.private final boolean
The field for thecanOpenByHand
record component.static final BlockSetType
static final BlockSetType
static final BlockSetType
private final SoundEvent
The field for thedoorClose
record component.private final SoundEvent
The field for thedoorOpen
record component.static final BlockSetType
static final BlockSetType
static final BlockSetType
static final BlockSetType
private final String
The field for thename
record component.static final BlockSetType
static final BlockSetType
private final SoundEvent
The field for thepressurePlateClickOff
record component.private final SoundEvent
The field for thepressurePlateClickOn
record component.private final SoundType
The field for thesoundType
record component.static final BlockSetType
static final BlockSetType
private final SoundEvent
The field for thetrapdoorClose
record component.private final SoundEvent
The field for thetrapdoorOpen
record component.private static final Set<BlockSetType>
static final BlockSetType
-
Constructor Summary
ConstructorDescriptionBlockSetType
(String p_272860_) BlockSetType
(String name, boolean canOpenByHand, SoundType soundType, SoundEvent doorClose, SoundEvent doorOpen, SoundEvent trapdoorClose, SoundEvent trapdoorOpen, SoundEvent pressurePlateClickOff, SoundEvent pressurePlateClickOn, SoundEvent buttonClickOff, SoundEvent buttonClickOn) Creates an instance of aBlockSetType
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebuttonClickOff
record component.Returns the value of thebuttonClickOn
record component.boolean
Returns the value of thecanOpenByHand
record component.Returns the value of thedoorClose
record component.doorOpen()
Returns the value of thedoorOpen
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.name()
Returns the value of thename
record component.Returns the value of thepressurePlateClickOff
record component.Returns the value of thepressurePlateClickOn
record component.static BlockSetType
register
(BlockSetType p_273033_) Returns the value of thesoundType
record component.final String
toString()
Returns a string representation of this record class.Returns the value of thetrapdoorClose
record component.Returns the value of thetrapdoorOpen
record component.static Stream<BlockSetType>
values()
-
Field Details
-
name
The field for thename
record component. -
canOpenByHand
private final boolean canOpenByHandThe field for thecanOpenByHand
record component. -
soundType
The field for thesoundType
record component. -
doorClose
The field for thedoorClose
record component. -
doorOpen
The field for thedoorOpen
record component. -
trapdoorClose
The field for thetrapdoorClose
record component. -
trapdoorOpen
The field for thetrapdoorOpen
record component. -
pressurePlateClickOff
The field for thepressurePlateClickOff
record component. -
pressurePlateClickOn
The field for thepressurePlateClickOn
record component. -
buttonClickOff
The field for thebuttonClickOff
record component. -
buttonClickOn
The field for thebuttonClickOn
record component. -
VALUES
-
IRON
-
GOLD
-
STONE
-
POLISHED_BLACKSTONE
-
OAK
-
SPRUCE
-
BIRCH
-
ACACIA
-
CHERRY
-
JUNGLE
-
DARK_OAK
-
CRIMSON
-
WARPED
-
MANGROVE
-
BAMBOO
-
-
Constructor Details
-
BlockSetType
-
BlockSetType
public BlockSetType(String name, boolean canOpenByHand, SoundType soundType, SoundEvent doorClose, SoundEvent doorOpen, SoundEvent trapdoorClose, SoundEvent trapdoorOpen, SoundEvent pressurePlateClickOff, SoundEvent pressurePlateClickOn, SoundEvent buttonClickOff, SoundEvent buttonClickOn) Creates an instance of aBlockSetType
record class.- Parameters:
name
- the value for thename
record componentcanOpenByHand
- the value for thecanOpenByHand
record componentsoundType
- the value for thesoundType
record componentdoorClose
- the value for thedoorClose
record componentdoorOpen
- the value for thedoorOpen
record componenttrapdoorClose
- the value for thetrapdoorClose
record componenttrapdoorOpen
- the value for thetrapdoorOpen
record componentpressurePlateClickOff
- the value for thepressurePlateClickOff
record componentpressurePlateClickOn
- the value for thepressurePlateClickOn
record componentbuttonClickOff
- the value for thebuttonClickOff
record componentbuttonClickOn
- the value for thebuttonClickOn
record component
-
-
Method Details
-
register
-
values
-
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 '=='. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
canOpenByHand
public boolean canOpenByHand()Returns the value of thecanOpenByHand
record component.- Returns:
- the value of the
canOpenByHand
record component
-
soundType
Returns the value of thesoundType
record component.- Returns:
- the value of the
soundType
record component
-
doorClose
Returns the value of thedoorClose
record component.- Returns:
- the value of the
doorClose
record component
-
doorOpen
Returns the value of thedoorOpen
record component.- Returns:
- the value of the
doorOpen
record component
-
trapdoorClose
Returns the value of thetrapdoorClose
record component.- Returns:
- the value of the
trapdoorClose
record component
-
trapdoorOpen
Returns the value of thetrapdoorOpen
record component.- Returns:
- the value of the
trapdoorOpen
record component
-
pressurePlateClickOff
Returns the value of thepressurePlateClickOff
record component.- Returns:
- the value of the
pressurePlateClickOff
record component
-
pressurePlateClickOn
Returns the value of thepressurePlateClickOn
record component.- Returns:
- the value of the
pressurePlateClickOn
record component
-
buttonClickOff
Returns the value of thebuttonClickOff
record component.- Returns:
- the value of the
buttonClickOff
record component
-
buttonClickOn
Returns the value of thebuttonClickOn
record component.- Returns:
- the value of the
buttonClickOn
record component
-