Class PlaceholderUtil

java.lang.Object
net.lewmc.essence.utils.placeholders.PlaceholderUtil

public class PlaceholderUtil extends Object
The tag utility replaces tags with preconfigured text (placeholders)
  • Constructor Details

    • PlaceholderUtil

      public PlaceholderUtil(Essence plugin, org.bukkit.command.CommandSender cs)
      Constructor
      Parameters:
      plugin - Reference to the main Essence class.
  • Method Details

    • replaceAll

      public String replaceAll(String text)
      Replaces tags with preconfigured text. This is used to search for and replace multiple placeholders at a time.
      Parameters:
      text - String - Text to search and replace.
      Returns:
      String - Resulting String
    • replaceSingle

      public String replaceSingle(String placeholder)
      Converts placeholders into strings. This is used to convert a single placeholder at a time.
      Parameters:
      placeholder - String - The placeholder to convert (without the braces)
      Returns:
      String - The string the placeholder becomes.