@param string $modelName

@return []
551722
private function getModelConfiguration($modelName)
    {
        if (!isset($this->annotationCache[$modelName])) {
            $reflection = new \ReflectionClass($modelName);
            $comment    = $reflection->getDocComment();
            $this->annotationCache[$modelName] = $this->parser->parse($comment);
        }

        $configuration = $this->annotationCache[$modelName];
        return $configuration;
    }
36431
public function getEmbeddedColumnsMappedTo(string $propertyName): array
    {
        $this->class->getProperty($propertyName);

        if (isset($this->propertyColumnNameMap[$propertyName])) {
            return [$this->propertyColumnNameMap[$propertyName]];
        }

        $relation = $this->getRelationMappedToProperty($propertyName);

        if ($relation) {
            return $relation->getParentColumnsToLoad();
        }

        throw InvalidOperationException::format('No columns mapped to property \'%s\'', $propertyName);
    }
17965
protected function getModelNamespace($modelName)
    {
        $path = Helpers::getAppNamespace() . rtrim(Config::getModelsPath(), '\\');

        return $path . '\\' . $modelName;
    }
359676
public function getModelArray(Model $model)
    {
        $result = [];
        foreach ($model->getAttributes() as $key => $value) {
            $result[] = ['type' => 'text', 'name' => $key, 'key' => $key.' :', 'value' => $value];
        }
        unset($result[0]);

        return $result;
    }
127583
public static function makeControllerName($modelName)
    {
        $name = self::getProperCaseFor($modelName, 'controller-name');
        $case = ucfirst(camel_case($name));

        if (!empty($postFix = Config::getControllerNamePostFix())) {
            return str_finish($case, $postFix);
        }

        return $case;
    }
332751
private function getPossibleValues(string $className): array
    {
        $metadata = $this->entityManager->getClassMetadata($className);
        $standard = array_values($metadata->fieldNames);
        $custom = $this->getCustomSortingNames($className);

        return array_merge($standard, $custom);
    }
850783
private function getOldFieldName($modelName, $fieldName)
    {
        $modelRenamedFields = ArrayHelper::getValue(
            $this->renamedFields,
            $modelName,
            []
        );
        if ($modelRenamedFields) {
            $fieldName = ArrayHelper::getValue(
                $modelRenamedFields,
                $fieldName,
                $fieldName
            );
        }

        return $fieldName;
    }
233945
public function updateOptions($modelName)
    {
        $fieldFactory = app('admin_field_factory');
        $response     = array();

        //iterate over the supplied constrained fields
        foreach ($this->request->input('fields', array()) as $field) {
            //get the constraints, the search term, and the currently-selected items
            $constraints   = array_get($field, 'constraints', array());
            $term          = array_get($field, 'term', array());
            $type          = array_get($field, 'type', false);
            $fieldName     = array_get($field, 'field', false);
            $selectedItems = array_get($field, 'selectedItems', false);

            $response[$fieldName] = $fieldFactory->updateRelationshipOptions($fieldName, $type, $constraints, $selectedItems, $term);
        }

        return response()->json($response);
    }
33449
protected function getCSVModuleAttr(string $moduleName) : array
    {
        if (empty($this->modules[$moduleName])) {
            return [];
        }

        return $this->modules[$moduleName];
    }
1227777
protected function getChoicesByEntity($entityName)
    {
        $choices = [];
        foreach ($this->em->getRepository($entityName)->findAll() as $choice) {
            $choices[(string) $choice] = $choice->getId();
        }

        return $choices;
    }
727792
public function getNormalizer($modelName) {
		if ($this->models->has($modelName)
				&& $this->models->get($modelName)->has('normalizer')) {
			return $this->models->get($modelName)->get('normalizer');
		}
		return new Map();
	}
932607
public function getFieldName($field, $modelName)
    {
        if (isset($this->_unionMapsTo[$modelName][$field])) {
            return $this->_unionMapsTo[$modelName][$field];
        }

        return $field;
    }
276563
public static function makeFormRequestName($modelName)
    {
        $name = self::getProperCaseFor($modelName, 'request-form-name');
        $case = ucfirst(camel_case($name));

        if (!empty($postFix = Config::getFormRequestNamePostFix())) {
            return str_finish($case, $postFix);
        }

        return $case;
    }
1137967
protected function getModuleIds(string $moduleName) : array
    {
        $table = TableRegistry::get($moduleName);
        $query = $table->find()
            ->limit(100)
            ->select($table->getPrimaryKey());

        $result = [];
        foreach ($query->all() as $entity) {
            $result[] = $entity->get($table->getPrimaryKey());
        }

        return $result;
    }
467804
public static function tableForeignKeys($tableName)
    {
        $result = ['inner' => [], 'outer' => []];
        foreach (Yii::$app->db->schema->tableSchemas as $table) {
            $foreignKeys = static::findConstraints($table);
            /** @var TableSchema $table */
            if ($table->name == $tableName) {
                $result['inner'] = $foreignKeys;
                continue;
            }
            foreach ($foreignKeys as $foreignKey) {
                if ($foreignKey['ftable'] == $tableName) {
                    $result['outer'][] = $foreignKey;
                }
            }
        }
        return $result;
    }
150065
public function getMessagesFor(string $fieldName) : array
    {
        $invalidInputException = $this->getInvalidInputExceptionFor($fieldName);

        if ($invalidInputException) {
            return $invalidInputException->getMessages();
        }

        $invalidFormSubmission = $this->getInnerFormSubmissionExceptionFor($fieldName);

        if ($invalidFormSubmission) {
            return $invalidFormSubmission->getFieldMessageMap();
        }

        return [];
    }
900185
public function getModelClass(string $modelName): ?string
    {
        if (isset($this->models[$modelName])) {
            return $this->models[$modelName];
        }

        return null;
    }