MyDAC
Dumps database objects to the stream.
TDADump
procedure BackupToStream(Stream: TStream; const Query: string = '');
Call the BackupToStream method to dump database objects to the stream.