PHP Class Prado\Xml\TXmlElement
TXmlElement represents an XML element node.
You can obtain its tag-name, attributes, text between the opening and closing
tags via the TagName, Attributes, and Value properties, respectively.
You can also retrieve its parent and child elements by Parent and Elements
properties, respectively.
TBD: xpath
Afficher le fichier
Open project: pradosoft/prado
Class Usage Examples
Méthodes publiques
Private Methods
Method Details
__construct()
public méthode
__toString()
public méthode
$element = new TXmlElement('tag');
echo $element;
or
$element = new TXmlElement('tag');
$xml = (string)$element;
getAttribute()
public méthode
getAttributes()
public méthode
public getAttributes ( ) : TMap |
Résultat |
Prado\Collections\TMap |
list of attributes |
getElementByTagName()
public méthode
public getElementByTagName ( $tagName ) : TXmlElement |
Résultat |
TXmlElement |
the first child element that has the specified tag-name, null if not found |
getElements()
public méthode
public getElements ( ) : TXmlElementList |
Résultat |
TXmlElementList |
list of child elements |
getElementsByTagName()
public méthode
public getElementsByTagName ( $tagName ) : Prado\Collections\TList |
Résultat |
Prado\Collections\TList |
list of all child elements that have the specified tag-name |
getHasAttribute()
public méthode
getHasElement()
public méthode
getParent()
public méthode
public getParent ( ) : TXmlElement |
Résultat |
TXmlElement |
parent element of this element |
getTagName()
public méthode
getValue()
public méthode
public getValue ( ) : string |
Résultat |
string |
text enclosed between opening and closing tag of this element |
setAttribute()
public méthode
setParent()
public méthode
setTagName()
public méthode
setValue()
public méthode
toString()
public méthode