@param string   $propertyName
@param string[] $excludedFields

@return bool
977237
private function shouldSkipField(string $propertyName, array $excludedFields): bool
    {
        if ('id' === $propertyName) {
            return true;
        }

        return \in_array($propertyName, $excludedFields, true);
    }
1342609
public function isVirtual(string $propertyName): bool
    {
        $this->existsOrFail($propertyName);
        return $this->isExistingPropertyVirtual($propertyName);
    }
354933
public function findDisplayableWorkspacesWithout(array $excludedWorkspaces)
    {
        $dql = '
            SELECT w
            FROM Claroline\CoreBundle\Entity\Workspace\Workspace w
            WHERE w.displayable = true
            AND w NOT IN (:excludedWorkspaces)
            ORDER BY w.name
        ';
        $query = $this->_em->createQuery($dql);
        $query->setParameter('excludedWorkspaces', $excludedWorkspaces);

        return $query->getResult();
    }
738298
public function getFieldByPropertyName(string $propertyName): ?FieldMetadataInterface
    {
        foreach ($this->fieldsMetadata as $fieldMetadata) {
            if ($propertyName === $fieldMetadata->getPropertyName()) {
                return $fieldMetadata;
            }
        }

        return null;
    }
837702
public function getPropertyMetadata($propertyName)
    {
        if (!isset($this->propertyMetadata[$propertyName])) {
            throw MappingException::mappingNotFound($this->name, $propertyName);
        }

        return $this->propertyMetadata[$propertyName];
    }
1185465
protected function hasProperty(string $propertyName): bool
    {
        if (count($this->values) === 1
          && isset($this->values['__value'])
          && 'value' === $propertyName) {
            return isset($this->values['__value']);
        }

        return isset($this->values[$propertyName]);
    }
97463
public function setExcluded($excluded = true)
    {
        foreach ($this->results as $name) {
            $this->columns->offsetGet($name)->setExcluded($excluded);
        }

        return $this;
    }
242538
protected function touchProperty($propertyName)
    {
        if (in_array('$' . $propertyName, $this->touchedProperties)) {
            return false;
        }
        $this->touchedProperties[] = '$' . $propertyName;
        return true;
    }
796550
public function addBooleanField(string $propertyName, string $dbFieldName = null)
    {
        return $this->addField(new BooleanField($propertyName, $dbFieldName));
    }
282466
private function isExistingPropertyGetterAvailable(string $propertyName): bool
    {
        assert($this->propertyExists($propertyName));
        if ($this->isExistingPropertyVirtual($propertyName)) {
            return !is_null($this->virtualGetters[$propertyName]);
        } else {
            return $this->realGetAvailable[$propertyName];
        }
    }
912179
public function isPropertyAnnotatedWith($className, $propertyName, $annotationClassName)
    {
        $className = $this->prepareClassReflectionForUsage($className);
        return isset($this->classReflectionData[$className][self::DATA_CLASS_PROPERTIES][$propertyName][self::DATA_PROPERTY_ANNOTATIONS][$annotationClassName]);
    }
817524
public function removeAllProperties(array $exclusions = [])
    {
        $this->parseStyleAttribute();

        $preservedProperties = [];

        foreach ($exclusions as $propertyName) {
            if (!is_string($propertyName)) {
                throw new InvalidArgumentException(sprintf('Property name must be a string, %s given', (is_object($propertyName) ? get_class($propertyName) : gettype($propertyName))));
            }

            if (!array_key_exists($propertyName, $this->properties)) {
                continue;
            }

            $preservedProperties[$propertyName] = $this->properties[$propertyName];
        }

        $this->properties = $preservedProperties;

        $this->updateStyleAttribute();

        return $this;
    }
1268334
public static function findPropertiesNames(
        string $classFqcn,
        array $excludedNames = [],
        array $excludedVisibility = []
    ) {
        $defaultVisibility = ['public' => true, 'protected' => true, 'private' => true, 'static' => true];
        $excludedVisibility = array_merge(
            $defaultVisibility,
            self::setGivenExcludedVisivilitiesToKeysWithValueFalse($excludedVisibility)
        );

        $reflectionClass = self::getReflectionClass($classFqcn);
        $reflectionPropertiesArray = $reflectionClass->getProperties();

        return self::filterProperties($excludedNames, $excludedVisibility, $reflectionPropertiesArray);
    }
44455
protected function preventPropertyModification($propertyName, $value) {
		if ($this->getPropertyValue($propertyName) != $value) {
			throw new Exception(sprintf('The property "%s" must not be changed.', $propertyName), 1387294954);
		}
	}
1368076
public function getProperty($propertyName)
    {
        if (isset($this->properties[$propertyName])) {
            return $this->properties[$propertyName];
        }

        $extendsClassDefinition = $this->getExtendsClassDefinition();
        if ($extendsClassDefinition) {
            if ($extendsClassDefinition->hasProperty($propertyName)) {
                return $extendsClassDefinition->getProperty($propertyName);
            }
        }

        return false;
    }
812009
protected function isExcludedByName(string $sectionName): bool
    {
        return count($this->excludedSections) > 0 && in_array($sectionName, $this->excludedSections);
    }
1126657
protected function getCachedRelationCount($propertyName)
    {
        if (array_key_exists($propertyName, $this->cachedRelationCountsCount)) {
            return $this->cachedRelationCountsCount[$propertyName];
        }

        $this->cachedRelationCountsCount[$propertyName] = $this->getUncachedRelationCount($propertyName);

        return $this->cachedRelationCountsCount[$propertyName];
    }