프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$simpleXMLElement | Instance of the wrapped SimpleXMLElement object |
메소드 | 설명 | |
---|---|---|
__construct ( string $xmlData ) | Creates a new SimpleXMLElement object | |
__toString ( ) : string | ||
getAttribute ( string $name, string | null | void $namespace = null ) : string | null | Returns the attribute for the given name. | |
getFirstChildByTagName ( string $tagName ) : |
Returns the first child matching the given tag name | |
registerXPathNamespace ( string $prefix, string $namespace ) : boolean | Creates a prefix/ns context for the next XPath query | |
removeNodesMatchingXPath ( string $path ) : void | Remove all nodes matching the given XPath query. | |
xpath ( string $path ) : |
Runs XPath query on XML data |
메소드 | 설명 | |
---|---|---|
wrapSimpleXMLElement ( |
Wraps the given element into an instance of the wrapper |
public __construct ( string $xmlData ) | ||
$xmlData | string | A well-formed XML string |
public getFirstChildByTagName ( string $tagName ) : |
||
$tagName | string | |
리턴 | The first child matching the tag name or NULL if none found |
public registerXPathNamespace ( string $prefix, string $namespace ) : boolean | ||
$prefix | string | The namespace prefix to use in the XPath query for the namespace given in "namespace". |
$namespace | string | The namespace to use for the XPath query. This must match a namespace in use by the XML document or the XPath query using "prefix" will not return any results. |
리턴 | boolean | TRUE on success or FALSE on failure. |
public removeNodesMatchingXPath ( string $path ) : void | ||
$path | string | An XPath path |
리턴 | void |
protected wrapSimpleXMLElement ( |
||
$element | Element to be wrapped | |
리턴 | The wrapped element or NULL if the given element is invalid |