Class StringFormatter

java.lang.Object
games.stendhal.common.StringFormatter

public class StringFormatter extends Object
Each parameter name in the control string is replaced by its value.
Author:
matthias
  • Constructor Details

    • StringFormatter

      public StringFormatter(String formatString)
      Creates a new instance of StringFormatter.
      Parameters:
      formatString - format string
  • Method Details

    • set

      public void set(String param, String value)
      Sets the value of a parameter
      Parameters:
      param - key
      value - value
    • set

      public void set(String param, int value)
      Sets the value of a parameter.
      Parameters:
      param - key
      value - value
    • toString

      public String toString()
      toString formats the string.
      Overrides:
      toString in class Object