TMtsDataModule = class(TRemoteDataModule, IAppServer, IObjectControl)
class PASCALIMPLEMENTATION DECLSPEC_DRTTI TMtsDataModule : public Datasnap::Databkr::TRemoteDataModule
TMtsDataModule encapsulates the objects and interfaces of a transactional application server.
Use a TMtsDataModule object as the central repository for all objects in a transactional application server that is written in Delphi. MTS data modules can contain any nonvisual components. . Typically these are data access components, such as datasets and the provider components that handle communication between these datasets and client applications. MTS data modules can also contain other nonvisual components, such as TTimer, or TImageList.
MTS data modules are dual-interface Automation servers that implement the IAppServer interface. Connection components on client applications are designed to look for this interface. The methods in this interface, however, do not call the SetComplete method, so the MTS data module is not transactional. You may want to expand the MTS data module's interface to provide alternate versions of these methods that use the MTS data module's transaction.
The default interaction between a client dataset and an MTS data module does not rely on state information, so it is safe to use the MTS data module with just-in-time activation. However, you may need to provide a mechanism for communicating persistent state information to take advantage of some features such as incremental fetches.
To create an MTS data module at design time, choose File|New|Other, and select Transactional Data Module from the multitier page of the new items dialog. If you are writing the application server in Delphi, the Transactional Data Module Wizard then creates a new descendant of TMtsDataModule that supports an interface that descends from IAppServer.