Class DBDependencyFactory


  • public class DBDependencyFactory
    extends java.lang.Object
    Establishes a relationship between an item stored in an application's Cache object and either a specific database table. This class cannot be inherited.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static DBCacheDependency createOleDbCacheDependency​(java.lang.String connectionString, java.lang.String dbCacheKey)
      Creates a new instance of OleDbCacheDependency class,using the supplied parameters.
      static DBCacheDependency createSqlCacheDependency​(java.lang.String connectionString, java.lang.String dbCacheKey)
      Creates a new instance of Sql7CacheDependency class, using the supplied parameters.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DBDependencyFactory

        public DBDependencyFactory()
    • Method Detail

      • createSqlCacheDependency

        public static DBCacheDependency createSqlCacheDependency​(java.lang.String connectionString,
                                                                 java.lang.String dbCacheKey)
        Creates a new instance of Sql7CacheDependency class, using the supplied parameters. Remarks: This static method is used to create SqlCacheDependency objects for SQL Server 7 and SQL Server 2000 products. You need to enable notification for both the table and the database containing the table before you can use this "DBCacheDependency" in your application.
        Parameters:
        connectionString - The connection string for establishing a connection with the database server where the database containing above mentioned table exists.
        dbCacheKey - The primary key of the record. Many dependency objects can be created based on the same primary key. When the record with this primary key is modified in the database, the associated item(s) in the cache expire(s).
        Returns:
        An SqlCacheDependency object based on the supplied parameters.
        See Also:
        DBCacheDependency
      • createOleDbCacheDependency

        public static DBCacheDependency createOleDbCacheDependency​(java.lang.String connectionString,
                                                                   java.lang.String dbCacheKey)
        Creates a new instance of OleDbCacheDependency class,using the supplied parameters. You need to enable notification for both the table and the database containing the table before you can use this "DBCacheDependency" in your application.
        Parameters:
        connectionString - The connection string for establishing a connection with the database server where the database containing above mentioned table exists.
        dbCacheKey - The primary key of the record. Many dependency objects can be created based on the same primary key. When the record with this primary key is modified in the database, the associated item(s) in the cache expire(s).
        Returns:
        An SqlCacheDependency object based on the supplied parameters
        See Also:
        DBCacheDependency