本文整理了Java中org.geotools.xsd.Node.setValue()
方法的一些代码示例,展示了Node.setValue()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Node.setValue()
方法的具体详情如下:
包路径:org.geotools.xsd.Node
类名称:Node
方法名:setValue
[英]Sets the value of the node.
[中]设置节点的值。
代码示例来源:origin: geotools/geotools
/**
*
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated modifiable
*/
public Object parse(ElementInstance instance, Node node, Object value) throws Exception {
List sections = node.getChildren("Section");
if (null != sections) {
for (Iterator iterator = sections.iterator(); iterator.hasNext(); ) {
Node child = (Node) iterator.next();
child.setValue(Section.get((String) child.getValue()));
}
}
return super.parse(instance, node, value);
}
代码示例来源:origin: geotools/geotools
@Override
public Object parse(ElementInstance instance, Node node, Object value) throws Exception {
Node attr = node.getAttribute("method");
if (null != attr) {
attr.setValue(MethodType.get((String) attr.getValue()));
}
return super.parse(instance, node, value);
}
}
代码示例来源:origin: geotools/geotools
/**
*
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated modifiable
*/
public Object parse(ElementInstance instance, Node node, Object value) throws Exception {
Node attr = node.getChild("containment");
if (null != attr) {
attr.setValue(ContainmentType.get((String) attr.getValue()));
}
return super.parse(instance, node, value);
}
代码示例来源:origin: geotools/geotools
public void endElement(String uri, String localName, String qName) throws SAXException {
// pop the last handler off of the stack
ElementHandler handler = (ElementHandler) handlers.pop();
// create a qName object from the string
String prefix = namespaces.getPrefix(uri);
QName qualifiedName =
prefix != null ? new QName(uri, localName, prefix) : new QName(uri, localName);
handler.endElement(qualifiedName);
endElementInternal(handler);
// if the upper most delegating handler, then end the document
if (handler instanceof DelegatingHandler
&& !handlers.isEmpty()
&& !(handlers.peek() instanceof DelegatingHandler)) {
DelegatingHandler dh = (DelegatingHandler) handler;
dh.endDocument();
// grabbed the parsed value
dh.getParseNode().setValue(dh.delegate.getParsedObject());
}
// pop namespace context
namespaces.popContext();
if (isCDATAEnding()) {
setCDATA(false);
}
}
内容来源于网络,如有侵权,请联系作者删除!