Returns an array of models

@return bool|array Array of models, or false
551746
public function get()
    {
        // Perform before hook
        $this->beforeGet();

        // Set basic query
        $this->db()->table($this->table)->select($this->columns)->limit($this->limit)->offset($this->offset)->orderBy($this->orderBy);

        // Resolve relationships
        $this->hasOne()->belongsToMany();

        // Get results
        $this->records = $this->db()->get();

        // Add has many relationships
        $this->hasMany();

        // Format relationships
        $this->formatBelongsToMany()->formatHasOne();

        // Perform after hook
        $this->afterGet();

        // Return query results
        return $this->records;
    }
843298
private static function get_models_with_user_data() {
        $models = \core_analytics\manager::get_all_models();
        foreach ($models as $modelid => $model) {
            $analyser = $model->get_analyser(['notimesplitting' => true]);
            if (!$analyser->processes_user_data()) {
                unset($models[$modelid]);
            }
        }
        return $models;
    }
729835
public function getAll()
    {
        $rest = $this->callService('GET', self::API_UPLOAD);

        return $rest->getModels(models\FileSystem\FileUpload::class);
    }
131350
public function toArray()
    {
        $result = [
            'name' => $this->init['name'],
            'apiVersion' => $this->init['apiVersion'],
            'baseUri' => isset($this->init['baseUri']) ? $this->init['baseUri'] : '',
            'description' => $this->init['description'],
        ];
        $result['operations'] = $this->operations;
        if (!empty($this->models)) {
            $result['models'] = $this->models;
        }

        return array_filter($result);
    }
1161252
public function getAll()
    {
        $result = $this->callService('GET', self::API_SHARE_LINK);

        return $result->getModels(models\FileSystem\ShareLink::class);
    }
932578
public static function all()
    {
        global $wpdb;

        $dbResults = $wpdb->get_results('SELECT * FROM ' . static::getTableName());
        $result = [];
        $model = get_called_class();
        foreach ($dbResults as $dbResult) {
            $modelObject = new $model();
            foreach (self::$columns as $column) {
                $modelObject->$column = $dbResult->$column;
            }
            $result[] = $modelObject;
        }

        return $result;
    }
255519
protected function getModels($refresh = false)
    {
        if ($this->_models === null || $refresh) {
            $this->_models = [];

            foreach ($this->data as $message) {
                $this->_models[] = [
                    'message' => $message[0],
                    'level' => $message[1],
                    'category' => $message[2],
                    'time' => $message[3] * 1000, // time in milliseconds
                    'trace' => $message[4]
                ];
            }
        }

        return $this->_models;
    }
68153
protected function getModelBuilds() {
        if (!$this->_modelBuilds) {
            $this->_modelBuilds = new ModelBuildList($this->version, $this->solution['sid']);
        }

        return $this->_modelBuilds;
    }
1161453
public function toArray()
    {
        $attr = !empty($this->getWarden()) ? $this->getWarden() : null;
        if (empty($attr)) {
            $attr = empty($this->getVisible()) ? $this->getFillable() : $this->getVisible();
        }
        $returnable = [];

        $f_model = \FormModel::using('plain')->withModel($this);
        foreach ($attr as $old => $new) {
            if (!empty($relations = $f_model->getRelationalDataAndModels($this, $old))) {
                $returnable[$new] = $relations;
            }
            if (stripos($old, '_id') !== false) {
                if (!empty($this->$new)) {
                    $returnable[$new] = $relations;
                }
            } else {
                if (isset($this->$old)) {
                    $returnable[$new] = $this->$old;
                }
            }
        }

        return $returnable;
    }
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;
    }
898266
public function show()
    {
        $dataProvider = new ActiveDataProvider(['query' => static::find()]);
        $dataProvider->sort->defaultOrder = ['sort' => SORT_ASC, 'id' => SORT_ASC];
        return $dataProvider->getModels();
    }
1022366
protected function loadModelTables()
    {
        $reader = $this->getModelReader();
        $tables = [];

        while ($reader->read()) {
            if ($reader->isModelTable()) {
                if ($table = $this->loadModelTable($reader->expand())) {
                    $tables[$table->getId()] = $table;
                } // if
            } // if
        } // while

        return $tables;
    }
1056944
public function getManagedModels()
    {
        $models = $this->getVersionedModels();

        // Normalize models to have their model class in array key and all names as the value are uppercased
        foreach ($models as $k => $v) {
            $archivedModels[$v] = array('title' => ucfirst(singleton($v)->i18n_plural_name()));
            unset($archivedModels[$k]);
        }

        return $archivedModels;
    }
937597
public function getModels($columns = array('*'))
    {
        // make sure that we select the version table, if the main table is selected
        $tempColumns = isset($this->query->columns)
            ? array_merge($columns, $this->query->columns)
            : $columns;
        foreach($tempColumns as $column) {
            $segments = explode('.', $column);
            if ($segments[0] == $this->model->getTable()) {
                $this->query->addSelect($this->model->getVersionTable().'.*');
                break;
            }
        }

        return parent::getModels($columns);
    }
102871
public static function load_default_models_for_all_components(): array {

        $tmp = [];

        foreach (\core_component::get_component_list() as $type => $components) {
            foreach (array_keys($components) as $component) {
                if ($loaded = static::load_default_models_for_component($component)) {
                    $tmp[$type][$component] = $loaded;
                }
            }
        }

        $result = [];

        if ($loaded = static::load_default_models_for_component('core')) {
            $result['core'] = $loaded;
        }

        if (!empty($tmp['core'])) {
            $result += $tmp['core'];
            unset($tmp['core']);
        }

        foreach ($tmp as $components) {
            $result += $components;
        }

        return $result;
    }
348388
public function toArray()
	{
		$output = $this->getAttributes();

		foreach ($this->relationships as $key => $value) {

			if ($value instanceof BaseModel) {
				$value = array($value->getSingularEntityName() => $value->toArray());
			}
			else {
				$value = $value->toArray();
			}

			$output = array_merge($output, $value);
		}

		return $output;
	}
1292719
protected function checkModels()
    {
        $models = func_get_args();
        //
        foreach ($models as $model) {
            if (!class_exists($model)) {
                $this->ModelNotFinded($model);
            }
        }
    }