Class PoolProperties.InterceptorDefinition

java.lang.Object
org.apache.tomcat.jdbc.pool.PoolProperties.InterceptorDefinition
All Implemented Interfaces:
Serializable
Enclosing class:
PoolProperties

public static class PoolProperties.InterceptorDefinition extends Object implements Serializable
Definition of a JDBC interceptor with its configuration properties.
See Also:
  • Field Details

  • Constructor Details

    • InterceptorDefinition

      public InterceptorDefinition(String className)
      Constructs an InterceptorDefinition with the given class name.
      Parameters:
      className - the interceptor class name
    • InterceptorDefinition

      public InterceptorDefinition(Class<?> cl)
      Constructs an InterceptorDefinition with the given class.
      Parameters:
      cl - the interceptor class
  • Method Details

    • getClassName

      public String getClassName()
      Returns the interceptor class name.
      Returns:
      the class name
    • addProperty

      public void addProperty(String name, String value)
      Adds a property with the given name and value.
      Parameters:
      name - the property name
      value - the property value
    • addProperty

      public void addProperty(PoolProperties.InterceptorProperty p)
      Adds the given interceptor property.
      Parameters:
      p - the property to add
    • getProperties

      public Map<String, PoolProperties.InterceptorProperty> getProperties()
      Returns the map of interceptor properties.
      Returns:
      the properties map
    • getInterceptorClass

      public Class<? extends JdbcInterceptor> getInterceptorClass() throws ClassNotFoundException
      Returns the interceptor class, loading it if necessary.
      Returns:
      the interceptor class
      Throws:
      ClassNotFoundException - if the class cannot be found