Set to View object

@param   string $var The variable to set
@param   mixed $val The value of the variable to set
@return  self
@see     \TemplateEngine\TemplateEngine::viewFallback()
437017
public function setToView($var, $val)
    {
        $args = func_get_args();
        array_shift($args);
        $this->viewFallback($var, $args, 'set');
        return $this;
    }
594817
public function setInspectTemplate($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\InspectTemplate::class);
        $this->inspect_template = $var;

        return $this;
    }
1144920
public function setDefaultData($key, $val = null)
    {
        if(is_array($key))
        {
            foreach($key as $k=>$v)
            {
                $this->setDefaultData($k, $v);
            }
        }
        else
        {
            $this->defaultData[$key] = $val;
        }

        return $this;
    }
1099189
public function setModel($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\AutoMl\V1beta1\Model::class);
        $this->model = $var;

        return $this;
    }
214640
public function setRefersTo($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\Debugger\V2\StatusMessage_Reference::class);
        $this->refers_to = $var;

        return $this;
    }
1040934
public function setStackTrace($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Trace\V2\StackTrace::class);
        $this->stack_trace = $var;

        return $this;
    }
1262292
public function set($key, $val)
    {
        // set the variable
        if (empty($key)) return $this;

        $node = new Node($this->mainNode, $key, $val);
        $this->mainNode->addChild($node);

        return $this;
    }
917396
protected function initViewVars($view)
    {
        $view->set('controller', $this->getName());
        $view->set('action', $this->getAction());

        if (method_exists($view, 'setRequest')) {
            $view->setRequest($this->getRequest());
        }

        return $view;
    }
1070165
public function setRunAttempt($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\BigQuery\DataTransfer\V1\ListTransferRunsRequest_RunAttempt::class);
        $this->run_attempt = $var;

        return $this;
    }
579773
public function setKMapEstimationResult($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\AnalyzeDataSourceRiskDetails_KMapEstimationResult::class);
        $this->writeOneof(7, $var);

        return $this;
    }
352424
public function set($variable, $value = null)
    {
        $this->variables[$variable] = array(
            'safe' => $this->htmlEncode($value),
            'unsafe' => $value
        );

        return $this;
    }
425736
public function setValue($value)
    {
        if ($value === Fallback::VALUE_TRUE) {
            $value = true;
        }

        if ($value === Fallback::VALUE_FALSE) {
            $value = false;
        }

        $this->value = $value;
        return $this;
    }
7330
public function setView($view, $variables = [])
    {
        if (!empty($variables)) {
            $this->with($variables);
        }

        $this->view = $view;
    }
505513
public function setEvent($var)
    {
        GPBUtil::checkMessage($var, \Rxnet\EventStore\Data\EventRecord::class);
        $this->event = $var;

        return $this;
    }
663113
protected function Div( $val )
	{
		if  (! $val->getIsNumeric() ) return $this;
		$value1 = $this->ToDecimal( null );
		$value2 = $val->ToDecimal( null );
		return $value1->Div( $value2 );
	}
463447
public function setLink($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Trace\V2\Span\Link::class);
        $this->link = $arr;

        return $this;
    }
1181168
public function setWindow($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Container\V1\MaintenanceWindow::class);
        $this->window = $var;

        return $this;
    }