public interface Metadatable
Modifier and Type | Method and Description |
---|---|
List<MetadataValue> |
getMetadata(String metadataKey)
Returns a list of previously set metadata values from the implementing
object's metadata store.
|
boolean |
hasMetadata(String metadataKey)
Tests to see whether the implementing object contains the given
metadata value in its metadata store.
|
void |
removeMetadata(String metadataKey,
Plugin owningPlugin)
Removes the given metadata value from the implementing object's
metadata store.
|
void |
setMetadata(String metadataKey,
MetadataValue newMetadataValue)
Sets a metadata value in the implementing object's metadata store.
|
void setMetadata(String metadataKey, 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 nullList<MetadataValue> getMetadata(String metadataKey)
metadataKey
- the unique metadata key being sought.boolean hasMetadata(String metadataKey)
metadataKey
- the unique metadata key being queried.void removeMetadata(String metadataKey, 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 © 2017. All rights reserved.