/**
* Reset internal pointer for xmlrpc values of type struct.
+ * @deprecated iterate directly over the object using foreach instead
*/
public function structreset()
{
* Return next member element for xmlrpc values of type struct.
*
* @return Value
+ *
+ * @deprecated iterate directly over the object using foreach instead
*/
public function structeach()
{
*
* @return integer
*
- * @deprecateduse count() instead
+ * @deprecated use count() instead
*/
public function structsize()
{
* @return ArrayIterator
*/
public function getIterator() {
- return new \ArrayIterator($this->me);
+ switch ($this->mytype) {
+ case 3:
+ return new \ArrayIterator($this->me['struct']);
+ case 2:
+ return new \ArrayIterator($this->me['array']);
+ case 1:
+ return new \ArrayIterator($this->me);
+ default:
+ return new \ArrayIterator();
+ }
+ return new \ArrayIterator();
}
}
\ No newline at end of file