Class ConfigValidator

java.lang.Object
org.apache.tika.config.ConfigValidator

public class ConfigValidator extends Object
Utility class for validating configuration parameters.
  • Method Details

    • mustNotBeEmpty

      public static void mustNotBeEmpty(String paramName, String paramValue) throws TikaConfigException
      Validates that a string parameter is not null or blank.
      Parameters:
      paramName - the name of the parameter (for error messages)
      paramValue - the value to validate
      Throws:
      TikaConfigException - if the value is null or blank
    • mustNotBeEmpty

      public static void mustNotBeEmpty(String paramName, Path paramValue) throws TikaConfigException
      Validates that a Path parameter is not null.
      Parameters:
      paramName - the name of the parameter (for error messages)
      paramValue - the value to validate
      Throws:
      TikaConfigException - if the value is null