protected function asArray($data)
	{
		$array = array();

		if (is_object($data))
		{
			$data = get_object_vars($data);
		}

		foreach ($data as $k => $v)
		{
			if (is_object($v) || is_array($v))
			{
				$array[$k] = $this->asArray($v);
			}
			else
			{
				$array[$k] = $v;
			}
		}

		return $array;
	}
protected function asArray($data)
	{
		$array = array();

		if (is_object($data))
		{
			$data = get_object_vars($data);
		}

		foreach ($data as $k => $v)
		{
			if (is_object($v) || is_array($v))
			{
				$array[$k] = $this->asArray($v);
			}
			else
			{
				$array[$k] = $v;
			}
		}

		return $array;
	}
protected function asArray ( $ data ) { $ array = array ( ) ; if ( is_object ( $ data ) ) { $ data = get_object_vars ( $ data ) ; } foreach ( $ data as $ k => $ v ) { if ( is_object ( $ v ) || is_array ( $ v ) ) { $ array [ $ k ] = $ this -> asArray ( $ v ) ; } else { $ array [ $ k ] = $ v ; } } return $ array ; }
Method to recursively convert an object of data to an array.

@param   object  $data  An object of data to return as an array.

@return  array  Array representation of the input object.

@since   1.0
Method to recursively convert an object of data to an array .