Class CayenneRuntimeFactory

java.lang.Object
com.avoka.core.util.CayenneRuntimeFactory

public class CayenneRuntimeFactory extends Object
A factory for creating CayenneRuntime objects.
Since:
4.0.0
  • Constructor Details

    • CayenneRuntimeFactory

      public CayenneRuntimeFactory()
    • CayenneRuntimeFactory

      public CayenneRuntimeFactory(boolean commitLogModuleFlag)
  • Method Details

    • setConfigurationLocation

      public CayenneRuntimeFactory setConfigurationLocation(String configurationLocation)
      Set cayenne domain configuration location.
      Parameters:
      configurationLocation - cayenne domain configuration location
      Returns:
      this Cayenne runtime factory
      Since:
      19.5.0
    • setQueryCache

      public CayenneRuntimeFactory setQueryCache(boolean queryCache)
      Set whether to use query caching.
      Parameters:
      queryCache - specify whether to use query caching
      Returns:
      this Cayenne runtime factory
      Since:
      5.1.7
    • setDataSourceFactory

      public CayenneRuntimeFactory setDataSourceFactory(org.apache.cayenne.configuration.server.DataSourceFactory dataSourceFactory)
      Set data source factory to use.
      Parameters:
      dataSourceFactory - the data source factory to use.
      Returns:
      this Cayenne runtime factory
      Since:
      5.1.7
    • setDefaultListener

      public CayenneRuntimeFactory setDefaultListener(org.apache.cayenne.LifecycleListener defaultListener)
      Set the default LifecycleListener.
      Parameters:
      defaultListener - specify whether to use query caching
      Returns:
      this Cayenne runtime factory
      Since:
      5.1.7
    • setLifecycleListeners

      public CayenneRuntimeFactory setLifecycleListeners(List lifecycleListeners)
      Set the list of LifecycleListeners.
      Parameters:
      lifecycleListeners - the list of LifecycleListeners
      Returns:
      this Cayenne runtime factory
      Since:
      5.1.7
    • setCommitLogModule

      public CayenneRuntimeFactory setCommitLogModule(org.apache.cayenne.di.Module commitLogModule)
      Set the commit log module
      Parameters:
      commitLogModule - the commit log module
      Returns:
      this Cayenne runtime factory
      Since:
      22.10.0
    • getServerRuntime

      public org.apache.cayenne.configuration.server.ServerRuntime getServerRuntime()
      Return the server runtime for the given Cayenne runtime configuration.
      Returns:
      the server runtime for the given Cayenne runtime configuration
      Since:
      5.1.7
    • getDataContext

      public org.apache.cayenne.access.DataContext getDataContext()
      Return the data context for the given Cayenne runtime configuration.
      Returns:
      the data context for the given Cayenne runtime configuration
      Since:
      5.1.7
    • clearQueryCacheGroup

      public static void clearQueryCacheGroup(String groupName)
      Clear server runtime instances query cache group for the given name.
      Parameters:
      groupName - the query cache group name (required)
      Since:
      5.1.7
    • invalidateCache

      public static void invalidateCache()
      Invalidate the config cache.
      Since:
      23.10.0