public interface Metadatable
| Modifier and Type | Method and Description |
|---|---|
@NotNull List<MetadataValue> |
getMetadata(@NotNull String metadataKey)
Returns a list of previously set metadata values from the implementing
object's metadata store.
|
boolean |
hasMetadata(@NotNull String metadataKey)
Tests to see whether the implementing object contains the given
metadata value in its metadata store.
|
void |
removeMetadata(@NotNull String metadataKey,
@NotNull Plugin owningPlugin)
Removes the given metadata value from the implementing object's
metadata store.
|
void |
setMetadata(@NotNull String metadataKey,
@NotNull MetadataValue newMetadataValue)
Sets a metadata value in the implementing object's metadata store.
|
void setMetadata(@NotNull @NotNull String metadataKey, @NotNull @NotNull MetadataValue newMetadataValue)
metadataKey - A unique key to identify this metadata.newMetadataValue - The metadata value to apply.IllegalArgumentException - If value is null, or the owning plugin
is null@NotNull @NotNull List<MetadataValue> getMetadata(@NotNull @NotNull String metadataKey)
metadataKey - the unique metadata key being sought.boolean hasMetadata(@NotNull @NotNull String metadataKey)
metadataKey - the unique metadata key being queried.void removeMetadata(@NotNull @NotNull String metadataKey, @NotNull @NotNull Plugin owningPlugin)
metadataKey - the unique metadata key identifying the metadata to
remove.owningPlugin - This plugin's metadata value will be removed. All
other values will be left untouched.IllegalArgumentException - If plugin is nullCopyright © 2021. All rights reserved.