Package com.kamikazejam.kamicommon.util
Class StringUtil
java.lang.Object
com.kamikazejam.kamicommon.util.StringUtil
- Direct Known Subclasses:
StringUtilP
A standalone compatible class for translating strings with color codes
Use StringUtilP for methods with players (translating PAPI placeholders) (part of the spigot-utils module)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String
capitalize
(String str) static String
static String
static @NotNull String
IntegerToRomanNumeral
(int input) Converts an integer to a Roman Numeral
Supports ONLY integers in the range [1, 3999] (inclusive)static String
listToString
(List<String> list) static String[]
static String
static String
static String[]
static String[]
static String
static String[]
static String
static String
protected static String
translateAlternateColorCodes
(String textToTranslate)
-
Field Details
-
COLOR_CHAR
public static final char COLOR_CHAR- See Also:
-
-
Constructor Details
-
StringUtil
public StringUtil()
-
-
Method Details
-
t
-
t
-
t
-
t
-
r
-
r
-
r
-
rt
-
rt
-
rt
-
listToString
-
combine
-
combine
-
subList
- Parameters:
string
- The String[] to splitstart
- The index to start at (inclusive)end
- The index to end at (exclusive)- Returns:
- The resulting String[]
-
reverseT
-
reverseT
-
reverseT
-
capitalize
-
IntegerToRomanNumeral
@NotNull public static @NotNull String IntegerToRomanNumeral(int input) throws IllegalArgumentException Converts an integer to a Roman Numeral
Supports ONLY integers in the range [1, 3999] (inclusive)- Returns:
- The Roman Numeral representation of the input integer
- Throws:
IllegalArgumentException
- if the input is not in the range [1, 3999]
-
translateAlternateColorCodes
-