Showing 1,528 of 2,291 total issues
Function createEntity
has a Cognitive Complexity of 83 (exceeds 5 allowed). Consider refactoring. Open
public function createEntity($className, array $data, &$hints = array())
{
$class = $this->em->getClassMetadata($className);
//$isReadOnly = isset($hints[Query::HINT_READ_ONLY]);
- Read upRead up
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
SQLAnywherePlatform
has 87 functions (exceeds 20 allowed). Consider refactoring. Open
class SQLAnywherePlatform extends AbstractPlatform
{
/**
* @var integer
*/
Function getSchemaFromMetadata
has a Cognitive Complexity of 81 (exceeds 5 allowed). Consider refactoring. Open
public function getSchemaFromMetadata(array $classes)
{
// Reminder for processed classes, used for hierarchies
$processedClasses = array();
$eventManager = $this->em->getEventManager();
- Read upRead up
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
UnitOfWork
has 84 functions (exceeds 20 allowed). Consider refactoring. Open
class UnitOfWork implements PropertyChangedListener
{
/**
* An entity is in MANAGED state when its persistence is managed by an EntityManager.
*/
Method loadMetadataForClass
has 312 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function loadMetadataForClass($className, ClassMetadata $metadata)
{
/* @var $metadata \Doctrine\ORM\Mapping\ClassMetadataInfo */
$class = $metadata->getReflectionClass();
if ( ! $class) {
File SqlitePlatform.php
has 682 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
File PostgreSqlPlatform.php
has 680 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Method getKeywords
has 302 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected function getKeywords()
{
return array(
'ABS',
'ALL',
File OraclePlatform.php
has 668 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
FPDF
has 78 functions (exceeds 20 allowed). Consider refactoring. Open
class FPDF
{
var $page; // current page number
var $n; // current object number
var $offsets; // array of object offsets
File DocParser.php
has 645 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Function Annotation
has a Cognitive Complexity of 71 (exceeds 5 allowed). Consider refactoring. Open
private function Annotation()
{
$this->match(DocLexer::T_AT);
// check if we have an annotation
- Read upRead up
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
PostgreSqlPlatform
has 75 functions (exceeds 20 allowed). Consider refactoring. Open
class PostgreSqlPlatform extends AbstractPlatform
{
/**
* @var bool
*/
SqlWalker
has 74 functions (exceeds 20 allowed). Consider refactoring. Open
class SqlWalker implements TreeWalker
{
/**
* @var string
*/
Function generateAssociationMappingPropertyDocBlock
has a Cognitive Complexity of 69 (exceeds 5 allowed). Consider refactoring. Open
protected function generateAssociationMappingPropertyDocBlock(array $associationMapping, ClassMetadataInfo $metadata)
{
$lines = array();
$lines[] = $this->spaces . '/**';
- Read upRead up
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
OraclePlatform
has 73 functions (exceeds 20 allowed). Consider refactoring. Open
class OraclePlatform extends AbstractPlatform
{
/**
* Assertion for Oracle identifiers.
*
Method exportClassMetadata
has 264 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function exportClassMetadata(ClassMetadataInfo $metadata)
{
$xml = new \SimpleXmlElement("<?xml version=\"1.0\" encoding=\"utf-8\"?><doctrine-mapping ".
"xmlns=\"http://doctrine-project.org/schemas/orm/doctrine-mapping\" " .
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" ".
Function tln_getnxtag
has a Cognitive Complexity of 65 (exceeds 5 allowed). Consider refactoring. Open
function tln_getnxtag($body, $offset)
{
if ($offset > strlen($body)) {
return false;
}
- Read upRead up
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
File MySqlPlatform.php
has 586 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
File class.smtp.php
has 578 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* PHPMailer RFC821 SMTP email transport class.
* PHP Version 5
* @package PHPMailer