Class Classname

All Implemented Interfaces:
ValueOfContractor, Serializable, CharSequence, Comparable<Classname>

public final class Classname extends AbstractTextType<Classname>
String type replacement for class names.
Since:
4.2.201
See Also:
  • Method Details

    • getPattern

      public static Pattern getPattern()
      Get the pattern for a classname.
      Returns:
      The classname pattern.
      Since:
      4.2.201
    • valueOf

      @Contract("null -> null") public static Classname valueOf(String string)
      Create an instance from String.

      Fulfills the ValueOfContractor marker.

      Parameters:
      string - The string to create from.
      Returns:
      The created instance or null, iff the given string is null.
      Throws:
      de.espirit.firstspirit.common.text.InvalidDesignatorException - If the given string does not match basic critera for being a language abbreviation.
      Since:
      4.2.201
    • setStrict

      public static void setStrict(boolean strict)
      Set the classname to be strict, i.e., an InvalidDesignatorException will be thrown in case of classnames not matching the pattern.

      Note: Strict settings only are local to the current thread!

      Parameters:
      strict - The strict mode to set.
      Since:
      4.2.201
    • isStrict

      public static boolean isStrict()
      Indicates the classname to work in strict mode. If not set, will default to false.
      Returns:
      true, if working in strict mode.
      Since:
      4.2.201