Namespace DbExport.Providers

Classes

BatchScriptExecutor

An implementation of the IScriptExecutor interface that executes SQL scripts using batch processing when supported by the database provider.

CodeGenerator

Base class for code generators that produce SQL scripts for database schema and data export. This class implements the visitor pattern to traverse the database schema and generate appropriate SQL statements. Derived classes should override the visit methods to provide provider-specific SQL generation logic. The class also manages output writing and supports options for controlling the export process, such as whether to include schema, data, foreign keys, etc. The class implements IDisposable to allow for proper resource management of the output stream, especially when writing to files.

MetaData

Represents a collection of metadata key-value pairs. This class is used to store additional information about the database schema items such as tables, table columns and/or keys. The keys are case-insensitive, allowing for flexible access to the metadata values.

NameOwnerPair

Represents a pair consisting of a name and an optional owner, commonly used to define database objects such as tables or types along with their associated schema or owner information.

ProviderNames

A static class that contains constant string values representing the names of supported database providers. These names are typically used to identify the specific database provider when configuring database connections or performing database operations.

SchemaProvider

A factory class that provides methods to create schema providers and retrieve database schemas based on the specified provider name, connection string, and optional schema filter.

SimpleScriptExecutor

Provides a simple implementation of the IScriptExecutor interface that executes SQL scripts against a database connection using the SqlHelper class.

Interfaces

ISchemaProvider

A common interface for schema providers, which are responsible for retrieving database schema information such as table names, column names, index names, foreign key names, and their associated metadata. This interface abstracts the underlying database provider implementation, allowing for flexibility and extensibility in supporting different database systems.

IScriptExecutor

Defines an abstraction for executing SQL scripts against a database connection.