Class StringUtil

java.lang.Object
ca.uhn.fhir.util.StringUtil

public class StringUtil extends Object
  • Constructor Details

  • Method Details

    • chompCharacter

      public static String chompCharacter(String theInput, char theCharacter)
      If a string ends with a given character, remove that character from the end of the string (as many times as it occurs at the end)
    • normalizeStringForSearchIndexing

      public static String normalizeStringForSearchIndexing(String theString)
    • toUtf8String

      public static String toUtf8String(byte[] theBytes)
    • left

      public static String left(String theString, int theCodePointCount)
      Gets the string prefix of the specified length.
      Parameters:
      theString - String to get the prefix from
      theCodePointCount - Length of the prefix in code points
      Returns:
      Returns the string prefix of the specified number of codepoints.
    • prependLineNumbers

      @Nonnull public static String prependLineNumbers(@Nonnull String theInput)