Showing 43 of 43 total issues
Function getSqlString
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
public function getSqlString()
{
$baseFace = $this->getBaseFace();
- 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
Method faceSetter
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function faceSetter($path, $value, FaceLoader $faceLoader = null)
{
// look the type of $needle then dispatch
if ( $path instanceof \Face\Core\EntityFaceElement) {
Method getColumnsReal
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getColumnsReal(){
if($this->isSilent()){
return [];
}
Function execute
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
public function execute($config = null)
{
if(null == $config){
$pdo = Config::getDefault()->getPdo();
- 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
Method read
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function read(\PDOStatement $stmt)
{
$this->unfoundPrecedence=array();
Method runOperations
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function runOperations(EntityInterface $instance, $array,InstancesKeeper $instanceKeeper, &$unfound){
foreach($this->operationsList as $k=> $operation) {
Method _proccessDumpFaceData
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
private static function _proccessDumpFaceData($data, $alreadyPrinted, $depth, $maxDepth = 30)
{
$nlStr=PHP_EOL;
Method getElement
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getElement($name, $offset = null, &$pieceOfPath = null)
{
if (StringUtils::beginsWith("this.", $name)) {
$name = substr($name, 5);
Function __whereINRelationOneIdentifierGetValues
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
protected function __whereINRelationOneIdentifierGetValues($entities, $itsColumn, EntityFaceElement $relatedElement)
{
$values = array();
- 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
Function getElement
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public function getElement($name, $offset = null, &$pieceOfPath = null)
{
if (StringUtils::beginsWith("this.", $name)) {
$name = substr($name, 5);
- 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
Function __doFQLTableNameStatic
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
public static function __doFQLTableNameStatic($path, $token = null, $escape = false)
{
if (null===$token) {
$token=self::$DOT_TOKEN;
}
- 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
Function generateCode
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
protected function generateCode(SelectQuery $FQuery)
{
$identityGetter = "\$identityGetter = [];\n";
$arrayDefault = "\$data = [];\n";
- 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
Function __construct
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
function __construct($params = array(), FaceLoader $faceLoader = null)
{
$this->faceLoader = $faceLoader;
$this->elements = array();
- 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
Avoid deeply nested control flow statements. Open
if ($parentQueryFace->getFace()->getName() === $element->getName()) {
/* @var $parentQueryFace QueryFace */
// D
// Look if parent and child refer to the same one
Function compile
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function compile(){
/* @var $facesToSelect QueryFace[] */
$facesToSelect["this"] = $this->selectBuilder->getBaseQueryFace();
$facesToSelect = array_merge($facesToSelect, $this->selectBuilder->getJoins());
- 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
Function getFaceForClass
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getFaceForClass($className)
{
$face = null;
if($this->faceClassExists($className)){
- 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
Function getFaceForName
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getFaceForName($name)
{
if($this->faceNameExists($name)){
return parent::getFaceForName($name);
}else{
- 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
Function getSqlString
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getSqlString()
{
$baseFace = $this->getBaseFace();
- 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
Function debugGetRelatedName
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected function debugGetRelatedName($e, EntityFace $face)
{
$names=[];
- 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
Function _includeIdentifiers
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected function _includeIdentifiers(&$columns){
foreach($this->face->getElements() as $elm){
if($elm->isValue() && $elm->isIdentifier()){
$realPath = $this->makePath($elm->getName());
if(!isset($columns[$realPath])) {
- 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"