Add missing @throws DBALException

parent 2494d9bc
......@@ -401,6 +401,8 @@ class Connection
* Returns the database server version if the underlying driver supports it.
*
* @return string|null
*
* @throws DBALException
*/
private function getServerVersion()
{
......@@ -626,6 +628,8 @@ class Connection
* @param int $level The level to set.
*
* @return int
*
* @throws DBALException
*/
public function setTransactionIsolation($level)
{
......@@ -638,6 +642,8 @@ class Connection
* Gets the currently active transaction isolation level.
*
* @return int The current transaction isolation level.
*
* @throws DBALException
*/
public function getTransactionIsolation()
{
......@@ -1226,6 +1232,8 @@ class Connection
/**
* @return bool
*
* @throws DBALException
*/
public function beginTransaction()
{
......@@ -1314,6 +1322,8 @@ class Connection
/**
* Commits all current nesting transactions.
*
* @throws DBALException
*/
private function commitAll(): void
{
......@@ -1442,6 +1452,8 @@ class Connection
* Gets the wrapped driver connection.
*
* @return DriverConnection
*
* @throws DBALException
*/
public function getWrappedConnection()
{
......@@ -1513,6 +1525,8 @@ class Connection
* @param string $type The name of the DBAL mapping type.
*
* @return mixed The converted value.
*
* @throws DBALException
*/
public function convertToDatabaseValue($value, $type)
{
......@@ -1527,6 +1541,8 @@ class Connection
* @param string $type The name of the DBAL mapping type.
*
* @return mixed The converted type.
*
* @throws DBALException
*/
public function convertToPHPValue($value, $type)
{
......@@ -1540,6 +1556,8 @@ class Connection
* @param DriverStatement $stmt The statement to bind the values to.
* @param mixed[] $params The map/list of named/positional parameters.
* @param int[]|string[] $types The parameter types (PDO binding types or DBAL mapping types).
*
* @throws DBALException
*/
private function _bindTypedValues(DriverStatement $stmt, array $params, array $types): void
{
......@@ -1581,6 +1599,8 @@ class Connection
* @param int|string|null $type The type to bind (PDO or DBAL).
*
* @return mixed[] [0] => the (escaped) value, [1] => the binding type.
*
* @throws DBALException
*/
private function getBindingInfo($value, $type)
{
......
......@@ -98,6 +98,7 @@ class PrimaryReadReplicaConnection extends Connection
*
* @param mixed[] $params
*
* @throws DBALException
* @throws InvalidArgumentException
*/
public function __construct(array $params, Driver $driver, ?Configuration $config = null, ?EventManager $eventManager = null)
......
......@@ -60,6 +60,8 @@ final class Connection implements ServerInfoAwareConnection
}
/**
* {@inheritDoc}
*
* @return Statement
*/
public function prepare(string $sql): StatementInterface
......
......@@ -3,6 +3,7 @@
namespace Doctrine\DBAL\Event\Listeners;
use Doctrine\Common\EventSubscriber;
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Event\ConnectionEventArgs;
use Doctrine\DBAL\Events;
......@@ -44,6 +45,8 @@ class OracleSessionInit implements EventSubscriber
/**
* @return void
*
* @throws DBALException
*/
public function postConnect(ConnectionEventArgs $args)
{
......
......@@ -2165,6 +2165,8 @@ abstract class AbstractPlatform
* a string that defines the complete column
*
* @return string DBMS specific SQL code portion that should be used to declare the column.
*
* @throws DBALException
*/
public function getColumnDeclarationSQL($name, array $field)
{
......
......@@ -2,6 +2,7 @@
namespace Doctrine\DBAL\Platforms;
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Schema\ForeignKeyConstraint;
use Doctrine\DBAL\Schema\Identifier;
use Doctrine\DBAL\Schema\Index;
......@@ -694,6 +695,8 @@ SQL
/**
* @return string[]
*
* @throws DBALException
*/
private function getPreAlterTableAlterPrimaryKeySQL(TableDiff $diff, Index $index)
{
......@@ -733,6 +736,8 @@ SQL
* @param TableDiff $diff The table diff to gather the SQL for.
*
* @return string[]
*
* @throws DBALException
*/
private function getPreAlterTableAlterIndexForeignKeySQL(TableDiff $diff)
{
......
......@@ -963,6 +963,8 @@ class SqlitePlatform extends AbstractPlatform
/**
* @return string[]|false
*
* @throws DBALException
*/
private function getSimpleAlterTableSQL(TableDiff $diff)
{
......
......@@ -3,6 +3,7 @@
namespace Doctrine\DBAL\Query;
use Doctrine\DBAL\Connection;
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Driver\Result;
use Doctrine\DBAL\ParameterType;
use Doctrine\DBAL\Query\Expression\CompositeExpression;
......@@ -202,6 +203,8 @@ class QueryBuilder
* for insert, update and delete statements.
*
* @return Result|int
*
* @throws DBALException
*/
public function execute()
{
......
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