Populate from an array.

@param array $data
329203
public function populate($data = array())
    {
        if (isset($data['answer']) && $data['answer'] !== null) {
            $this->answer = $data['answer'];
        }

        if (isset($data['explanation']) && $data['explanation'] !== null) {
            $this->explanation = $data['explanation'];
        }

        if (isset($data['jsonData']) && $data['jsonData'] !== null) {
            $this->jsonData = $data['jsonData'];
        }

        if (isset($data['type']) && $data['type'] !== null) {
            $this->type = $data['type'];
        }

        if (isset($data['position']) && $data['position'] !== null) {
            $this->position = $data['position'];
        }

        if (isset($data['image']) && $data['image'] !== null) {
            $this->image = $data['image'];
        }

        if (isset($data['video']) && $data['video'] !== null) {
            $this->video = $data['video'];
        }

        if (isset($data['points']) && $data['points'] !== null) {
            $this->points = $data['points'];
        }

        if (isset($data['correct']) && $data['correct'] !== null) {
            $this->correct = $data['correct'];
        }
    }
1081007
public function populate($data = array())
    {
        parent::populate($data);

        if (isset($data['postDisplayMode']) && $data['postDisplayMode'] !== null) {
            $this->postDisplayMode = $data['postDisplayMode'];
        }

        if (isset($data['voteAnonymous']) && $data['voteAnonymous'] !== null) {
            $this->voteAnonymous = $data['voteAnonymous'];
        }
    }
1026583
private function addEdgesFromArray(array $data)
    {
        $_edgeClass = $this->_edgeClass;

        $this->_result[] = $_edgeClass::createFromArray($data, $this->_options);
    }
1215989
public function populate($data = array())
    {
        $this->value = (isset($data['value']) && $data['value'] !== null) ? $data['value'] : null;
        $this->active = (isset($data['active']) && $data['active'] !== null) ? $data['active'] : null;
        $this->winning = (isset($data['winning']) && $data['winning'] !== null) ? $data['winning'] : null;
    }
1017963
public static function fromArray(array $data)
	{
		return new self(
			!empty($data['code'])    ? $data['code']    : null,
			!empty($data['message']) ? $data['message'] : null,
			!empty($data['data'])    ? $data['data']    : null
		);
	}
854903
public function populate($data)
	{
		// Loop through all the elements assigned and attempt to assign a value to them.
		foreach ( $this->getContents() as $item )
		{
			if ($item instanceof InputContainer)
			{
				// This is another Fieldset or Form so needs to be populated too
				$item->populate($data);
			}
			// This is a regular input so it can be populated
			else
			{
				// Convert the name to a dot notation for better searching
				$key = $this->inputNameToKey($item->getName());
				$value = Arr::get($data, $key);

				if ( !is_null($value) )
				{
					$item->setValue($value);
				}
			}
		}

		return $this;
	}
1374487
protected function fromArray($data)
    {
        if (empty($data)) {
            return $this;
        }

        $this->data = array_replace_recursive($this->data, $data);

        return $this;
    }
437957
public function setFromArray(array $data): void
	{
		foreach ($data as $parameter => $value) {
			$this->bindings[$parameter] = new Bind($parameter, $value);
		}
	}
700869
public function populate(array $data = [], array $ignore = ['createdByUserId', 'createdDate', 'createdReason'])
    {
        if (!empty($data['domainId']) && !in_array('domainId', $ignore)) {
            $this->setDomainId($data['domainId']);
        }
        // @bc support
        if (!empty($data['domain']) && !in_array('domainId', $ignore)) {
            $this->setDomainName($data['domain']);
        }
        if (!empty($data['domainName']) && !in_array('domainId', $ignore)) {
            $this->setDomainName($data['domainName']);
        }

        if (!empty($data['primaryDomain'])
            && !in_array('domainId', $ignore)
            && $data['primaryDomain'] instanceof Domain
        ) {
            $this->setPrimaryDomain($data['primaryDomain']);
        }
        // @bc support
        if (!empty($data['primary'])
            && !in_array('domainId', $ignore)
            && $data['primary'] instanceof Domain
        ) {
            $this->setPrimaryDomain($data['primary']);
        }
    }
1295759
private function fromArray(array $data)
    {
        $this->browserName = $data['browser_name'];
        $this->browserVersion = $data['browser_version'];
        $this->browserEngine = $data['browser_engine'];
        $this->operatingSystem = $data['operating_system'];
        $this->device = $data['device'];
    }
895807
public final function load(array $data): self
    {
        foreach ($data as $key => $value) {
            $this->set($key, $value);
        }

        return $this;
    }
1169390
final public function create(array $data)
    {
        $this->query->setStartInsert($data);
        
        $this->query->prepare()->bindValuesForInsert($data)->execute();

        $this->setRowCount();

        $this->query->close();
    }
1036009
function load($data = [])
    {
        foreach ($this as $k => $v) {
            if ($k == 'table' || $k == 'where') {
                continue;
            }
            if (isset($data[$k])) {
                $this->$k = $data[$k];
            }
        }
    }
1162492
public function fromArray(array $array) {
        $rows = count($array);
        for ($i=$rows;$i-->0;) {
            $this[$i]->fromArray($array[$i]);
        }
    }
787282
public function setFromArray(array $data): void
    {
        foreach ($data as $key => $value) {
            $this->container[$key] = $value;
        }
    }
1090576
public function setArray(array $data)
    {
        foreach ($data as $key => $value)
        {
            array_set($this->settings,$key,$value);
        }

        $this->save($this->path, $this->filename);
        $this->load($this->path, $this->filename);
    }
1289096
public function fill($data)
    {
        // Field value is already setted.
//        if (!is_null($this->value)) {
//            return;
//        }

        $this->data = $data;

        if (is_array($this->column)) {
            foreach ($this->column as $key => $column) {
                $this->value[$key] = Arr::get($data, $column);
            }

            return;
        }

        $this->value = Arr::get($data, $this->column);
        if (isset($this->customFormat) && $this->customFormat instanceof \Closure) {
            $this->value = call_user_func($this->customFormat, $this->value);
        }
    }