Commit 9975da98 authored by Benjamin Eberlei's avatar Benjamin Eberlei

Revert "[DBAL-756] Add new method AbstractPlatform#getVendor()."

This reverts commit 5a46f577.
parent b5158740
# Upgrade to 2.5
## New abstract method `getVendor` on `AbstractPlatform`
Because we have been getting more and more version specific platforms
it is necessary to detect platforms based on the vendor, not on their version names.
For this a new method `abstract public function getVendor()` was introduced on
the `AbstractPlatform`.
If you have a custom platform that extends from `AbstractPlatform` you need to provide
this method as of version 2.5 of DBAL.
## datetime Type uses date_create() as fallback
Before 2.5 the DateTime type always required a specific format, defined in
......
......@@ -337,13 +337,6 @@ abstract class AbstractPlatform
*/
abstract public function getName();
/**
* Gets the name of the vendor, independent of version.
*
* @return string
*/
abstract public function getVendor();
/**
* Registers a doctrine type to be used in conjunction with a column type of this platform.
*
......
......@@ -107,14 +107,6 @@ class DB2Platform extends AbstractPlatform
return 'db2';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'db2';
}
/**
* {@inheritDoc}
*/
......
......@@ -40,14 +40,6 @@ class DrizzlePlatform extends AbstractPlatform
return 'drizzle';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'drizzle';
}
/**
* {@inheritDoc}
*/
......
......@@ -795,14 +795,6 @@ class MySqlPlatform extends AbstractPlatform
return 'mysql';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'mysql';
}
/**
* {@inheritDoc}
*/
......
......@@ -810,14 +810,6 @@ LEFT JOIN user_cons_columns r_cols
return 'oracle';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'oracle';
}
/**
* {@inheritDoc}
*/
......
......@@ -874,14 +874,6 @@ class PostgreSqlPlatform extends AbstractPlatform
return 'postgresql';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'postgresql';
}
/**
* {@inheritDoc}
*
......
......@@ -1005,14 +1005,6 @@ class SQLAnywherePlatform extends AbstractPlatform
return 'sqlanywhere';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'sqlanywhere';
}
/**
* Obtain DBMS specific SQL code portion needed to set a primary key
* declaration to be used in statements like ALTER TABLE.
......
......@@ -1286,14 +1286,6 @@ class SQLServerPlatform extends AbstractPlatform
return 'mssql';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'sqlserver';
}
/**
* {@inheritDoc}
*/
......
......@@ -486,14 +486,6 @@ class SqlitePlatform extends AbstractPlatform
return 'sqlite';
}
/**
* {@inheritDoc}
*/
public function getVendor()
{
return 'sqlite';
}
/**
* {@inheritDoc}
*/
......
......@@ -56,12 +56,6 @@ class MockPlatform extends \Doctrine\DBAL\Platforms\AbstractPlatform
{
return 'mock';
}
public function getVendor()
{
return 'mock';
}
protected function initializeDoctrineTypeMappings() {
}
protected function getVarcharTypeDeclarationSQLSnippet($length, $fixed)
......
......@@ -72,10 +72,6 @@ class DatabasePlatformMock extends \Doctrine\DBAL\Platforms\AbstractPlatform
{
return 'mock';
}
public function getVendor()
{
return 'mock';
}
protected function initializeDoctrineTypeMappings() {
}
protected function getVarcharTypeDeclarationSQLSnippet($length, $fixed)
......@@ -89,4 +85,4 @@ class DatabasePlatformMock extends \Doctrine\DBAL\Platforms\AbstractPlatform
{
throw DBALException::notSupported(__METHOD__);
}
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment