public function dump($depth = 3, \SplObjectStorage $dumped = null)
	{
		// Check if we should initialise the recursion tracker.
		if ($dumped === null)
		{
			$dumped = new \SplObjectStorage;
		}

		// Add this object to the dumped stack.
		$dumped->attach($this);

		// Setup a container.
		$dump = new \stdClass;

		// Dump all object properties.
		foreach (array_keys($this->properties) as $property)
		{
			// Get the property.
			$dump->$property = $this->dumpProperty($property, $depth, $dumped);
		}

		return $dump;
	}
public function dump($depth = 3, \SplObjectStorage $dumped = null)
	{
		// Check if we should initialise the recursion tracker.
		if ($dumped === null)
		{
			$dumped = new \SplObjectStorage;
		}

		// Add this object to the dumped stack.
		$dumped->attach($this);

		// Setup a container.
		$dump = new \stdClass;

		// Dump all object properties.
		foreach (array_keys($this->properties) as $property)
		{
			// Get the property.
			$dump->$property = $this->dumpProperty($property, $depth, $dumped);
		}

		return $dump;
	}
public function dump ( $ depth = 3 , \ SplObjectStorage $ dumped = null ) { // Check if we should initialise the recursion tracker. if ( $ dumped === null ) { $ dumped = new \ SplObjectStorage ; } // Add this object to the dumped stack. $ dumped -> attach ( $ this ) ; // Setup a container. $ dump = new \ stdClass ; // Dump all object properties. foreach ( array_keys ( $ this -> properties ) as $ property ) { // Get the property. $ dump -> $ property = $ this -> dumpProperty ( $ property , $ depth , $ dumped ) ; } return $ dump ; }
Dumps the data properties into a stdClass object, recursively if appropriate.

@param   integer            $depth   The maximum depth of recursion (default = 3).
For example, a depth of 0 will return a stdClass with all the properties in native
form. A depth of 1 will recurse into the first level of properties only.
@param   \SplObjectStorage  $dumped  An array of already serialized objects that is used to avoid infinite loops.

@return  \stdClass  The data properties as a simple PHP stdClass object.

@since   1.0
Dumps the data properties into a stdClass object recursively if appropriate .