Class TextProcessor

java.lang.Object
com.gophers.utilities.TextProcessor

public class TextProcessor extends Object
Utility class for processing and comparing text strings.
  • Constructor Details

    • TextProcessor

      public TextProcessor()
      Default constructor for TextProcessor class. Initializes a new instance of the TextProcessor.
  • Method Details

    • compareString

      public static boolean compareString(String expected, String actual)
      Compares two strings by checking if the sanitized actual string contains the sanitized expected string.
      Parameters:
      expected - The expected substring to look for.
      actual - The string to be checked for containing the expected substring.
      Returns:
      True if the actual string contains the expected substring, false otherwise.
    • matchString

      public static boolean matchString(String expected, String actual)
      Compares two strings by checking if they are identical after sanitization.
      Parameters:
      expected - The expected string.
      actual - The actual string to compare.
      Returns:
      True if the sanitized strings are identical, false otherwise.