The LazySchemaDiffProvider is responsible for lazily generating the from schema when diffing two schemas to produce a migration.
The OrmSchemaProvider class is responsible for creating a Doctrine\DBAL\Schema\Schema instance from the mapping information provided by the Doctrine ORM. This is then used to diff against your current database schema to produce a migration to bring your database in sync with the ORM mapping information.
The SchemaDiffProvider class is responsible for providing a Doctrine\DBAL\Schema\Schema instance that represents the current state of your database. A clone of this Schema instance is passed to each of your migrations so that you can manipulate the Schema object. Your manipulated Schema object is then compared to the original Schema object to produce the SQL statements that need to be executed.
The StubSchemaProvider takes a Doctrine\DBAL\Schema\Schema instance through the constructor and returns it from the createSchema() method.
The SchemaDiffProviderInterface defines the interface used to provide the from and to schemas and to produce the SQL queries needed to migrate.
The SchemaProviderInterface defines the interface used to create a Doctrine\DBAL\Schema\Schema instance that represents the current state of your database.