Package net.minestom.server.tag
Interface Taggable
- All Superinterfaces:
TagReadable
,TagWritable
- All Known Subinterfaces:
CommandSender
,ItemMeta.Builder
,ItemMetaView.Builder
- All Known Implementing Classes:
AbstractInventory
,AnvilInventory
,BannerMeta.Builder
,BeaconInventory
,BrewingStandInventory
,BundleMeta.Builder
,Chunk
,CompassMeta.Builder
,ConsoleSender
,CrossbowMeta.Builder
,Damage
,DynamicChunk
,EnchantedBookMeta.Builder
,EnchantmentTableInventory
,Entity
,EntityCreature
,EntityDamage
,EntityProjectile
,EntityProjectileDamage
,ExperienceOrb
,FireworkEffectMeta.Builder
,FireworkMeta.Builder
,FurnaceInventory
,Instance
,InstanceContainer
,Inventory
,ItemEntity
,LeatherArmorMeta.Builder
,LightingChunk
,LivingEntity
,MapMeta.Builder
,Player
,PlayerHeadMeta.Builder
,PlayerInventory
,PlayerProjectile
,PositionalDamage
,PotionMeta.Builder
,ServerSender
,SharedInstance
,ShieldMeta.Builder
,VillagerInventory
,WritableBookMeta.Builder
,WrittenBookMeta.Builder
-
Method Summary
Modifier and TypeMethodDescriptiondefault <T> @UnknownNullability T
Reads the specified tag.default boolean
Returns if a tag is present.default void
default <T> void
Writes the specified type.@NotNull TagHandler
-
Method Details
-
tagHandler
-
getTag
Description copied from interface:TagReadable
Reads the specified tag.- Specified by:
getTag
in interfaceTagReadable
- Type Parameters:
T
- the tag type- Parameters:
tag
- the tag to read- Returns:
- the read tag, null if not present
-
hasTag
Description copied from interface:TagReadable
Returns if a tag is present.- Specified by:
hasTag
in interfaceTagReadable
- Parameters:
tag
- the tag to check- Returns:
- true if the tag is present, false otherwise
-
setTag
Description copied from interface:TagWritable
Writes the specified type.- Specified by:
setTag
in interfaceTagWritable
- Type Parameters:
T
- the tag type- Parameters:
tag
- the tag to writevalue
- the tag value, null to remove
-
removeTag
- Specified by:
removeTag
in interfaceTagWritable
-