SqlCacheDependencyDatabase Constructors

Definition

Initializes a new instance of the SqlCacheDependencyDatabase class.

Overloads

SqlCacheDependencyDatabase(String, String)

Initializes a new instance of the SqlCacheDependencyDatabase class with the passed parameters.

SqlCacheDependencyDatabase(String, String, Int32)

Initializes a new instance of the SqlCacheDependencyDatabase class.

SqlCacheDependencyDatabase(String, String)

Initializes a new instance of the SqlCacheDependencyDatabase class with the passed parameters.

public:
 SqlCacheDependencyDatabase(System::String ^ name, System::String ^ connectionStringName);
public SqlCacheDependencyDatabase (string name, string connectionStringName);
new System.Web.Configuration.SqlCacheDependencyDatabase : string * string -> System.Web.Configuration.SqlCacheDependencyDatabase
Public Sub New (name As String, connectionStringName As String)

Parameters

name
String

A string that specifies the name used by SqlCacheDependencyDatabase to identify the database.

connectionStringName
String

A string that specifies the name of the connection string in the connectionStrings section to use to connect to this database.

Examples

The following example shows how to use this constructor.


SqlCacheDependencyDatabase dbElement1 =
    new SqlCacheDependencyDatabase(
    "dataBase1", "dataBaseElement1");
Dim dbElement1 As SqlCacheDependencyDatabase = _
New SqlCacheDependencyDatabase( _
    "dataBase1", "dataBaseElement1")

Applies to

SqlCacheDependencyDatabase(String, String, Int32)

Initializes a new instance of the SqlCacheDependencyDatabase class.

public:
 SqlCacheDependencyDatabase(System::String ^ name, System::String ^ connectionStringName, int pollTime);
public SqlCacheDependencyDatabase (string name, string connectionStringName, int pollTime);
new System.Web.Configuration.SqlCacheDependencyDatabase : string * string * int -> System.Web.Configuration.SqlCacheDependencyDatabase
Public Sub New (name As String, connectionStringName As String, pollTime As Integer)

Parameters

name
String

A string that specifies the name used by SqlCacheDependencyDatabase to identify the database.

connectionStringName
String

A string that specifies the name of the connection string in the connectionStrings section to use to connect to this database.

pollTime
Int32

The database polling time, in milliseconds.

Examples

The following example shows how to use this constructor.

SqlCacheDependencyDatabase dbElement0 =
    new SqlCacheDependencyDatabase(
    "dataBase", "dataBaseElement", 500);
Dim dbElement0 As SqlCacheDependencyDatabase = _
New SqlCacheDependencyDatabase( _
    "dataBase", "dataBaseElement", 500)

Applies to