Class RealEstateSign
java.lang.Object
me.EtienneDx.RealEstate.RealEstateSign
A utility wrapper for a Bukkit
Sign
used by the RealEstate plugin.
This class provides methods to set sign lines, update the sign, and check whether a given sign is a RealEstate sign (by comparing its header).
-
Constructor Summary
ConstructorsConstructorDescriptionRealEstateSign
(org.bukkit.block.Sign sign) Constructs a new RealEstateSign wrapper for the provided sign. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Checks if this sign is a RealEstate sign.void
Sets the text on the specified line of the sign.void
update
(boolean force) Updates the sign state.
-
Constructor Details
-
RealEstateSign
public RealEstateSign(org.bukkit.block.Sign sign) Constructs a new RealEstateSign wrapper for the provided sign.- Parameters:
sign
- the sign to wrap
-
-
Method Details
-
setLine
Sets the text on the specified line of the sign.- Parameters:
line
- the line index to set (typically 0-3)value
- the text value to display on the line
-
update
public void update(boolean force) Updates the sign state.- Parameters:
force
- if true, forces the update even if the sign is not changed
-
isRealEstateSign
public boolean isRealEstateSign()Checks if this sign is a RealEstate sign.It compares the header text of the sign with the expected header defined in the configuration.
- Returns:
- true if the sign's header matches the RealEstate header; false otherwise
-