Enum Class HighlightingStyle
java.lang.Object
java.lang.Enum<HighlightingStyle>
org.sgrewritten.stargate.network.portal.formatting.HighlightingStyle
- All Implemented Interfaces:
Serializable
,Comparable<HighlightingStyle>
,Constable
The highlighting characters to use around a portal or network name
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionThe highlighting to use for personal networksA variant of GREATER_LESSER_THANHighlightingStyle generally used for terminal gatesThe highlighting to use around a portal's destinationThe highlighting to use around a portal's nameNo highlighting at all.The highlighting to use around a normal network nameThe highlighting used for the destination server of legacy bungee stargates -
Method Summary
Modifier and TypeMethodDescriptiongetHighlightedName
(String name) Gets the given name with the highlighting appliedstatic HighlightingStyle
getHighlightType
(String highlightedText) static String
getNameFromHighlightedText
(String highlightedName) Gets the plain name from a name with highlightingstatic HighlightingStyle
Returns the enum constant of this class with the specified name.static HighlightingStyle[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
MINUS_SIGN
The highlighting to use around a portal's name -
LESSER_GREATER_THAN
The highlighting to use around a portal's destination -
GREATER_LESSER_THAN
HighlightingStyle generally used for terminal gates -
ROUNDED_BRACKETS
The highlighting to use around a normal network name -
SQUARE_BRACKETS
The highlighting used for the destination server of legacy bungee stargates -
CURLY_BRACKETS
The highlighting to use for personal networks -
DOUBLE_GREATER_LESSER_THAN
A variant of GREATER_LESSER_THAN -
NOTHING
No highlighting at all. Just a workaround, really
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getHighlightedName
Gets the given name with the highlighting applied- Parameters:
name
-The name to highlight
- Returns:
The highlighted name
-
getPrefix
- Returns:
The prefix of this highlight
-
getSuffix
- Returns:
The suffix of this highlight
-
getHighlightType
-
getNameFromHighlightedText
Gets the plain name from a name with highlighting- Parameters:
highlightedName
-The highlighted name
- Returns:
The plain name
-