RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TCustomCachedDataSet Class

TCustomCachedDataSet is the base class for client datasets that cache data from an internal source dataset.

Pascal
TCustomCachedDataSet = class(TCustomClientDataSet);
C++
class TCustomCachedDataSet : public TCustomClientDataSet;

TCustomCachedDataSet is the common base class for client datasets that contain an internal provider and source dataset. TCustomCachedDataSet descendants provide a simple way to cache updates. Unlike TClientDataSet, which has no associated data access mechanism, each TCustomCachedDataSet descendant is associated with a specific data access mechanism such as BDE, dbExpress, or InterBaseExpress. 

TCustomCachedDataSet descendants use an internal dataset to fetch the data from a database server and an internal provider to package that data into data packets and to apply updates. Thus, TCustomCachedDataSet descendants work much like TClientDataSet when it is connected to a local source dataset via a provider, except that the source dataset and provider are internal. 

TCustomCachedDataSet surfaces some of the properties and events of the internal dataset and provider so that you can specify the database server from which to fetch data, indicate what data to fetch from that server, influence what information is included in data packets, and provide input on the updating process. 

Like other client datasets, TCustomCachedDataSet descendants can read from and write to a dedicated file on disk. The internal provider and source dataset are not needed for working with file-based data, making TClientDataSet a more suitable choice if you are writing a purely file-based application. However, the ability to work with a file on disk makes TCustomCachedDataSet descendants well suited to "briefcase model" applications. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!