[OmniFaces utilities] The
getTextContent()
method returns the trimmed text content of given node. This uses the getFirstChild().getNodeValue()
instead of getTextContent()
to workaround some buggy JAXP implementations.Method:
Usage:
import
org.omnifaces.util.Xml;
...
for (int i =
0; i < welcomeFileList.getLength(); i++) {
String content =
Xml.getTextContent(welcomeFileList.item(i));
// do something with the content
}
Niciun comentariu :
Trimiteți un comentariu