public function offsetUnset($offset)
	{
		if (!$this->offsetExists($offset))
		{
			// Do nothing if the offset does not exist.
			return;
		}

		// Check for special handling of unsetting the current position.
		if ($offset == $this->current)
		{
			// Get the current position.
			$keys = $this->keys();
			$position = array_search($this->current, $keys);

			// Check if there is an object before the current object.
			if ($position > 0)
			{
				// Move the current position back one.
				$this->current = $keys[$position - 1];
			}
			else
			{
				// We are at the start of the keys AND let's assume we are in a foreach loop and `next` is going to be called.
				$this->current = false;
			}
		}

		unset($this->objects[$offset]);
	}
public function offsetUnset($offset)
	{
		if (!$this->offsetExists($offset))
		{
			// Do nothing if the offset does not exist.
			return;
		}

		// Check for special handling of unsetting the current position.
		if ($offset == $this->current)
		{
			// Get the current position.
			$keys = $this->keys();
			$position = array_search($this->current, $keys);

			// Check if there is an object before the current object.
			if ($position > 0)
			{
				// Move the current position back one.
				$this->current = $keys[$position - 1];
			}
			else
			{
				// We are at the start of the keys AND let's assume we are in a foreach loop and `next` is going to be called.
				$this->current = false;
			}
		}

		unset($this->objects[$offset]);
	}
public function offsetUnset ( $ offset ) { if ( ! $ this -> offsetExists ( $ offset ) ) { // Do nothing if the offset does not exist. return ; } // Check for special handling of unsetting the current position. if ( $ offset == $ this -> current ) { // Get the current position. $ keys = $ this -> keys ( ) ; $ position = array_search ( $ this -> current , $ keys ) ; // Check if there is an object before the current object. if ( $ position > 0 ) { // Move the current position back one. $ this -> current = $ keys [ $ position - 1 ] ; } else { // We are at the start of the keys AND let's assume we are in a foreach loop and `next` is going to be called. $ this -> current = false ; } } unset ( $ this -> objects [ $ offset ] ) ; }
Unsets an offset in the iterator.

@param   mixed  $offset  The object offset.

@return  void

@since   1.0
Unsets an offset in the iterator .