SimpleXMLIterator在SimpleXMLElement对象的所有节点上提供递归迭代。
## 方法:
```
class SimpleXMLElement implements Traversable {
/* 方法 */
public __construct(
string $data,
int $options = 0,
bool $dataIsURL = false,
string $namespaceOrPrefix = "",
bool $isPrefix = false
)
public addAttribute(string $qualifiedName, string $value, ?string $namespace = null): void
public addChild(string $qualifiedName, ?string $value = null, ?string $namespace = null): ?SimpleXMLElement
public asXML(?string $filename = null): string|bool
public attributes(?string $namespaceOrPrefix = null, bool $isPrefix = false): ?SimpleXMLElement
public children(?string $namespaceOrPrefix = null, bool $isPrefix = false): ?SimpleXMLElement
public count(): int
public getDocNamespaces(bool $recursive = false, bool $fromRoot = true): array|false
public getName(): string
public getNamespaces(bool $recursive = false): array
public registerXPathNamespace(string $prefix, string $namespace): bool
public __toString(): string
public xpath(string $expression): array|null|false
}
```
- 空白目录
- iterable接口
- 接口Traversable继承Iterator接口
- 类 RarArchive 继承Traversable接口
- 类SimpleXMLElement继承Traversable接口
- 类SimpleXMLIterator 继承SimpleXMLElement类
- 类IntlRuleBasedBreakIterator实现Traversable接口
- 类IntlCodePointBreakIterator实现Traversable接口
- 类DocResult 实现BaseResult和Traversable
- 类Result 实现\BaseResult和Traversable
- 类RowResult实现\BaseResult 和Traversable
- 类SqlStatementResult 实现BaseResult 和Traversable
- 接口IteratorAggregate 继承Traversable
- 类DOMNodeList 实现IteratorAggregate, Countable
- 类DOMNamedNodeMap 实现IteratorAggregate, Countable