Skip to main content

Caché Managed Provider Classes: Part 2

The following table lists the principal Caché Managed Provider classes, provides a brief description of each, and lists some of their important properties and methods:

Class Description Important Properties\Methods
CacheConnection Represents the physical connection between an application and a data source. Instantiate the connection using a connection string. Use CacheConnection to represent a connection between Caché and ADO.NET. Methods include:
  • Open — Opens a connection.

  • Close — Closes a connection.

  • Connection(string connectString) — Constructor. Instantiates a connection using a connection string containing port, address, namespace, user name, and password information.

CacheCommand

Represents a command, for example an SQL command, that can be executed against the database.

Methods include:

  • Command(string "SQL") — Constructor. Instantiates a representation of an SQL command.

  • Execute — Executes the command and returns data.

  • ExecuteNonQuery — Executes a non-query, for example an INSERT.

CacheDataAdapter

Mediates between the DataSet object and the data source. Decouples them so that a DataSet can be filled with data from multiple data sources.

Methods include:

  • Fill — Fills a DataSet with data from the data source.

  • Update — Resolves any changes made in a DataSet back to the data source or sources.

CacheDataReader

Used only for very efficient retrieval of a read-only stream of data. Supports only forward movement through the data stream. Results are retrieved as the query executes and stored in network cache.

Methods include:

  • Read — Retrieves a a single row of the query result table from the network cache.

  • GetInt, GetString, and so on — Retrieves data from the current row using either the column name or number.

FeedbackOpens in a new tab