Class BannerMock
java.lang.Object
be.seeseemelk.mockbukkit.block.state.BlockStateMock
be.seeseemelk.mockbukkit.block.state.TileStateMock
be.seeseemelk.mockbukkit.block.state.BannerMock
- All Implemented Interfaces:
Banner
,BlockState
,TileState
,Metadatable
,Nameable
,PersistentDataHolder
Mock implementation of a
Banner
.- See Also:
-
Constructor Summary
ModifierConstructorDescriptionprotected
BannerMock
(@NotNull BannerMock state) Constructs a newBannerMock
by cloning the data from an existing one.protected
BannerMock
(@NotNull Block block) Constructs a newBannerMock
for the providedBlock
.BannerMock
(@NotNull Material material) Constructs a newBannerMock
for the providedMaterial
. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addPattern
(@NotNull Pattern pattern) @Nullable net.kyori.adventure.text.Component
void
customName
(@Nullable net.kyori.adventure.text.Component customName) @NotNull DyeColor
@Nullable String
@NotNull Pattern
getPattern
(int i) @NotNull BannerMock
This returns a copy of thisBlockStateMock
.int
@NotNull Pattern
removePattern
(int i) void
setBaseColor
(@NotNull DyeColor color) void
setCustomName
(@Nullable String name) void
setPattern
(int i, @NotNull Pattern pattern) void
setPatterns
(@NotNull List<Pattern> patterns) Methods inherited from class be.seeseemelk.mockbukkit.block.state.TileStateMock
getPersistentDataContainer, isSnapshot
Methods inherited from class be.seeseemelk.mockbukkit.block.state.BlockStateMock
checkType, checkType, checkType, checkType, copy, equals, getBlock, getBlockData, getChunk, getData, getDrops, getDrops, getDrops, getLightLevel, getLocation, getLocation, getMetadata, getRawData, getType, getWorld, getX, getY, getZ, hashCode, hasMetadata, isCollidable, isPlaced, mockState, removeMetadata, setBlockData, setData, setMetadata, setRawData, setType, update, update, update
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.bukkit.block.BlockState
copy, getBlock, getBlockData, getChunk, getData, getDrops, getDrops, getDrops, getLightLevel, getLocation, getLocation, getRawData, getType, getWorld, getX, getY, getZ, isCollidable, isPlaced, setBlockData, setData, setRawData, setType, update, update, update
Methods inherited from interface org.bukkit.metadata.Metadatable
getMetadata, hasMetadata, removeMetadata, setMetadata
Methods inherited from interface org.bukkit.block.TileState
getPersistentDataContainer, isSnapshot
-
Constructor Details
-
BannerMock
- Parameters:
material
- The material this state is for.
-
BannerMock
- Parameters:
block
- The block this state is for.
-
BannerMock
Constructs a newBannerMock
by cloning the data from an existing one.- Parameters:
state
- The state to clone.
-
-
Method Details
-
getSnapshot
Description copied from class:BlockStateMock
This returns a copy of thisBlockStateMock
. Inheritents of this class should override this method!- Specified by:
getSnapshot
in classTileStateMock
- Returns:
- A snapshot of this
BlockStateMock
.
-
getBaseColor
- Specified by:
getBaseColor
in interfaceBanner
-
setBaseColor
- Specified by:
setBaseColor
in interfaceBanner
-
getPatterns
- Specified by:
getPatterns
in interfaceBanner
-
setPatterns
- Specified by:
setPatterns
in interfaceBanner
-
addPattern
- Specified by:
addPattern
in interfaceBanner
-
getPattern
- Specified by:
getPattern
in interfaceBanner
-
removePattern
- Specified by:
removePattern
in interfaceBanner
-
setPattern
- Specified by:
setPattern
in interfaceBanner
-
numberOfPatterns
public int numberOfPatterns()- Specified by:
numberOfPatterns
in interfaceBanner
-
customName
@Nullable public @Nullable net.kyori.adventure.text.Component customName()- Specified by:
customName
in interfaceNameable
-
customName
public void customName(@Nullable @Nullable net.kyori.adventure.text.Component customName) - Specified by:
customName
in interfaceNameable
-
getCustomName
- Specified by:
getCustomName
in interfaceNameable
-
setCustomName
- Specified by:
setCustomName
in interfaceNameable
-