Airship\Engine\Lens::store PHP Method

store() public method

Persist state for later rendering.
public store ( string $key, mixed $val ) : self
$key string Index
$val mixed Value
return self
    public function store(string $key, $val) : self
    {
        $this->stored[$key] = $val;
        return $this;
    }

Usage Example

Example #1
0
 /**
  * Grab a lens
  *
  * @param string $name
  * @param mixed $value
  * @return Lens
  */
 protected function storeLensVar(string $name, $value) : Lens
 {
     return $this->airship_lens_object->store($name, $value);
 }