Empty the final stack to get the objects inside.

@return array The content of the final stack.
777972
protected function emptyFinal($count)
    {
        $returnValue = array();

        while ($count > 0) {
            $returnValue[] = array_pop($this->final);
            $count--;
        }

        return array_reverse($returnValue);
    }
1349270
public function clear() {
        $children = $this->children();
        foreach ($children as $file) {
            $file->delete();
        }
        return $this;
    }
214151
protected static function makeEmpty()
    {
        $self  = self::getInstance();

        $self->optionWhere     = [];
        $self->optionWhereData = [];
        $self->optionJoin      = [];
        $self->optionLimit     = null;
        $self->optionSelect    = null;
        $self->table_name      = null;

        return $self;
    }
1045056
public function removeEmpty(): Utility
    {
        $filteredBag = array_filter($this->bag, function ($value) {
            return !empty($value);
        });

        if (!$this->isAssociative()) {
            $filteredBag = array_values($filteredBag);
        }

        return new static($filteredBag);
    }
1139794
public function removeLast(): self
    {
        $tmpArray = $this->getArray();

        \array_pop($tmpArray);

        return static::create(
            $tmpArray,
            $this->iteratorClass,
            false
        );
    }
590427
public function clear(){
        foreach(get_object_vars($this) as $property => $value){
            if(is_array($value)){
                $tempValue = [];
            } else {
                $tempValue = null;
            }

            $this->{$property} = $tempValue;
        }
    }
36488
protected function filterEmpty()
    {
        $vars = $this->toArray();
        foreach ($vars as $name => $value) {
            if (!strlen($value)) {
                unset($this->{$name});
            }
        }
    }
651751
final public function clearContent()
    {
        $reset = [
            &$this->content,
            &$this->contentRaw,
        ];

        foreach ($reset as &$property) {
            $property = [];
        }
    }
375981
public function remove()
    {
        $args = func_get_args();
        
        if (count($args) == 0) {
            return $this;
        }
        
        $last = array_pop($args);
        
        $pointer = &$this->data;
        foreach ($args as $i => $step) {
            if (!isset($pointer[$step])
                || !is_array($pointer[$step])
            ) {
                return $this;
            }

            $pointer = &$pointer[$step];
        }
        
        unset($pointer[$last]);
        
        return $this;
    }
1154960
public function clear()
    {
        $this->wheres  = array();
        $this->sets    = array();
        $this->havings = array();
        $this->orders  = array();
        $this->binds   = array();
        $this->limit   = null;
        $this->offset  = null;

        return $this;
    }
1256282
public function clear()
	{
		$classvars = get_class_vars(__CLASS__);

		foreach ($classvars as $property => $value)
		{
			if ('_s_' == substr($property, 0, 3)) // Don't touch static variables
			{
				continue;
			}

			unset($this->$property);
			$this->$property = $value;
		}

		$objvars = get_object_vars($this);

		foreach ($objvars as $property => $value)
		{
			if (!array_key_exists($property, $classvars))
			{
				unset($this->$property);
			}
		}

		return true;
	}
631321
public function pop()
    {
        $this->internalDataListUpdate();
        if (isset($this->internalDataListData[0])) {
            $this->internalDataListUpdateValueIfNeeded($this->internalDataListData, sizeof($this->internalDataListData) - 1);
            return array_pop($this->internalDataListData);
        }
        return null;
    }
101287
public function clear()
    {
        $this->defaults = [];
        $this->types = [];
        $this->requires = [];
        $this->notNullables = [];

        return $this;
    }
527752
public function getValues()
    {
        if ($this->isEmpty()) {
            return [];
        }

        if ($this->hasElement()) {
            return $this->values;
        }

        $values = [];

        foreach ($this->stack as $where) {
            $values[] = $where->getValues();
        }

        return call_user_func_array('array_merge', $values);
    }
93123
public function clear() {
		$this->_value = null;
		$this->getConnection()->getClient()->delete($this->name);
		return $this;
	}
784298
public function toArray() {

        $properties = get_object_vars($this);

        foreach($properties as $var => &$value) {
            if(gettype($value)  === 'object') {
                unset($properties[$var]);
            }
        }

        return $properties;
    }
1051854
static public function destroyAll()
    {
        $models = call_user_func_array(get_called_class() . '::where', func_get_args())->take();
        foreach ($models as $m) {
            $m->destroy();
        }
        return $models;
    }