Showing 9 of 10 total issues

Oci8Connection has 23 functions (exceeds 20 allowed). Consider refactoring.
Open

class Oci8Connection extends AbstractOci8Base implements Oci8ConnectionInterface
{
    /**
     * Connection constructor.
     * @param $username
Severity: Minor
Found in src/Oci8Connection.php - About 2 hrs to fix

    Method __construct has 7 arguments (exceeds 4 allowed). Consider refactoring.
    Open

        public function __construct($name, $value, $size, $precision, $scale, $type, $rawType)
    Severity: Major
    Found in src/Oci8Field.php - About 50 mins to fix

      Method bindArrayByName has 5 arguments (exceeds 4 allowed). Consider refactoring.
      Open

          public function bindArrayByName($name, &$varArray, $maxTableLength, $maxItemLength = -1, $type = SQLT_AFC)
      Severity: Minor
      Found in src/Oci8Statement.php - About 35 mins to fix

        Method bindArrayByName has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            public function bindArrayByName($name, &$varArray, $maxTableLength, $maxItemLength = -1, $type = SQLT_AFC);
        Severity: Minor
        Found in src/Oci8StatementInterface.php - About 35 mins to fix

          Method __construct has 5 arguments (exceeds 4 allowed). Consider refactoring.
          Open

                  $username,
                  $password,
                  $connectionString = null,
                  $characterSet = null,
                  $sessionMode = null
          Severity: Minor
          Found in src/Oci8Connection.php - About 35 mins to fix

            Method connect has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                    $username,
                    $password,
                    $connectionString = null,
                    $characterSet = null,
                    $sessionMode = null
            Severity: Minor
            Found in src/Oci8PersistentConnection.php - About 35 mins to fix

              Method connect has 5 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                      $username,
                      $password,
                      $connectionString = null,
                      $characterSet = null,
                      $sessionMode = null
              Severity: Minor
              Found in src/Oci8Connection.php - About 35 mins to fix

                Method connect has 5 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                        $username,
                        $password = null,
                        $connectionString = null,
                        $characterSet = null,
                        $sessionMode = 0
                Severity: Minor
                Found in src/Oci8SingletonConnection.php - About 35 mins to fix

                  Function getErrorHandler has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                  Open

                      protected static function getErrorHandler()
                      {
                          if (!static::$errorHandler) {
                              static::$errorHandler = function ($severity, $message, $file = '', $line = 0) {
                                  restore_error_handler();
                  Severity: Minor
                  Found in src/AbstractOci8Base.php - About 35 mins to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Severity
                  Category
                  Status
                  Source
                  Language