java.lang.Object
com.github.imdabigboss.easydatapack.api.utils.StringUtil

public class StringUtil extends Object
Some utilities for strings.
  • Constructor Details

    • StringUtil

      public StringUtil()
  • Method Details

    • toRoman

      public static @NonNull String toRoman(int number)
      Converts an integer to a roman numeral.
      Parameters:
      number - the number to convert
      Returns:
      the roman numeral, or 0 because 0 doesn't exist in roman numerals
    • color

      public static @NonNull String color(@NonNull String str)
    • color

      public static @NonNull List<String> color(@NonNull List<String> list)
    • removeColors

      public static @NonNull String removeColors(@NonNull String str)
      Removes all the colours from a string.
      Parameters:
      str - the string to remove colours from
      Returns:
      the string without colours