@Retention(value=RUNTIME)
@Target(value=METHOD)
public @interface StringProvider
Usage: @StringProvider String method(UUID playerUUID)
The returned value is limited to 100 characters, remainder will be clipped.
If the value is a player name, provide value for playerName=true. This will allow linking between pages.
Modifier and Type | Required Element and Description |
---|---|
java.lang.String |
text
Text displayed before the value, limited to 50 characters.
|
Modifier and Type | Optional Element and Description |
---|---|
java.lang.String |
description
Text displayed when hovering over the value, limited to 150 characters.
|
Color |
iconColor
Color preference of the plugin.
|
Family |
iconFamily
Family of Font Awesome icon.
|
java.lang.String |
iconName
Name of Font Awesome icon.
|
boolean |
playerName
Determine if this value represents a Player name, for example a mayor of a town.
|
int |
priority
Display-priority of the value, highest value is placed top most.
|
boolean |
showInPlayerTable
When the parameter is set to
true the value from this Provider is shown on a table alongside players. |
public abstract java.lang.String text
Should inform the user what the value represents, for example "Town Name", "Pet Name"
public abstract int priority
Two values with same priority may appear in a random order.
Integer.MAX_VALUE
.public abstract java.lang.String description
Should be used to clarify what the value is if not self evident, for example text: "Power", description: "Faction power, affects ability of faction to perform actions. Regenerates"
public abstract boolean playerName
true
if the name can be used as a link to another player's page.public abstract java.lang.String iconName
See https://fontawesome.com/icons (select 'free')) for icons and their Family
.
public abstract Family iconFamily
See https://fontawesome.com/icons (select 'free')) for icons and their Family
.
public abstract Color iconColor
This color will be set as the default color to use for plugin's elements.