Class PatternFactoryBean

All Implemented Interfaces:
Aware, BeanClassLoaderAware, BeanFactoryAware, DisposableBean, FactoryBean<Pattern>, InitializingBean

public class PatternFactoryBean
extends AbstractComponentAwareFactoryBean<Pattern>
Factory bean for Pattern. Allows us to inject property based case sensitivity.
  • Field Details

    • caseSensitive

      @Nullable private String caseSensitive
      Whether the we are case sensitive or not.
    • regexp

      @Nullable private String regexp
      The regular expressions.
  • Constructor Details

    • PatternFactoryBean

      public PatternFactoryBean()
  • Method Details

    • getObjectType

      public Class<?> getObjectType()
      Specified by:
      getObjectType in interface FactoryBean<Pattern>
      Specified by:
      getObjectType in class AbstractFactoryBean<Pattern>
    • getCaseSensitive

      public String getCaseSensitive()
      set case sensitivity.
      Returns:
      Returns the caseSensitive.
    • setCaseSensitive

      public void setCaseSensitive​(@Nullable String what)
      get case sensitivity.
      Parameters:
      what - The value to set.
    • getRegexp

      @Nullable public String getRegexp()
      Get the regular expression.
      Returns:
      Returns the regexp.
    • setRegexp

      public void setRegexp​(@Nonnull String what)
      Set the regular expression.
      Parameters:
      what - what to set.
    • doCreateInstance

      protected Pattern doCreateInstance() throws Exception
      Call the parent class to create the instance.
      Specified by:
      doCreateInstance in class AbstractComponentAwareFactoryBean<Pattern>
      Returns:
      the bean.
      Throws:
      Exception - if needed.