本文整理了Java中com.google.gwt.user.client.Element.getNodeName()
方法的一些代码示例,展示了Element.getNodeName()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Element.getNodeName()
方法的具体详情如下:
包路径:com.google.gwt.user.client.Element
类名称:Element
方法名:getNodeName
暂无
代码示例来源:origin: com.google.gwt/gwt-servlet
if ("body".equals(getElement().getNodeName().toLowerCase(Locale.ROOT))) {
return;
代码示例来源:origin: org.geomajas/geomajas-client-gwt2-impl
/**
* Clone a single SVG element.
*
* @param source
* The source SVG element.
* @return Returns the clone.
*/
private static Element clone(Element source) {
if (source == null || source.getNodeName() == null) {
return null;
}
if ("#text".equals(source.getNodeName())) {
return Document.get().createTextNode(source.getNodeValue()).cast();
}
Element clone = createElementNS(Dom.NS_SVG, source.getNodeName());
cloneAttributes(source, clone);
for (int i = 0; i < source.getChildCount(); i++) {
Element child = source.getChild(i).cast();
clone.appendChild(clone(child));
}
return clone;
}
代码示例来源:origin: org.geomajas/geomajas-gwt-client-impl
/**
* Clone a single SVG element.
*
* @param source
* The source SVG element.
* @return Returns the clone.
*/
private static Element clone(Element source) {
if (source == null || source.getNodeName() == null) {
return null;
}
if ("#text".equals(source.getNodeName())) {
return Document.get().createTextNode(source.getNodeValue()).cast();
}
Element clone = createElementNS(Dom.NS_SVG, source.getNodeName());
cloneAttributes(source, clone);
for (int i = 0; i < source.getChildCount(); i++) {
Element child = source.getChild(i).cast();
clone.appendChild(clone(child));
}
return clone;
}
代码示例来源:origin: org.geomajas/geomajas-client-common-gwt
/**
* Clone a single SVG element.
*
* @param source
* The source SVG element.
* @return Returns the clone.
*/
public Element cloneSvgElement(Element source) {
if (source == null || source.getNodeName() == null) {
return null;
}
if ("#text".equals(source.getNodeName())) {
return Document.get().createTextNode(source.getNodeValue()).cast();
}
Element clone = createElementNS(Dom.NS_SVG, source.getNodeName(), Dom.createUniqueId());
cloneAttributes(source, clone);
for (int i = 0; i < source.getChildCount(); i++) {
Element child = source.getChild(i).cast();
clone.appendChild(cloneSvgElement(child));
}
return clone;
}
代码示例来源:origin: org.overlord/overlord-commons-gwt
/**
* @see com.google.gwt.user.client.ui.Panel#add(com.google.gwt.user.client.ui.Widget)
*/
@Override
public void add(Widget w) {
if (w == null)
throw new NullPointerException("Cannot add a null widget."); //$NON-NLS-1$
w.removeFromParent();
children.add(w);
Element li;
if (w.getElement().getNodeName().toLowerCase().equals("li")) { //$NON-NLS-1$
// The widget is a list item. Simply use it.
li = w.getElement();
} else {
// The widget needs wrapped with a list item.
li = Document.get().createLIElement().cast();
DOM.appendChild(li, w.getElement());
}
liMap.put(w, li);
DOM.appendChild(getElement(), li);
adopt(w);
}
代码示例来源:origin: net.wetheinter/gwt-user
if ("body".equals(getElement().getNodeName().toLowerCase(Locale.ROOT))) {
return;
代码示例来源:origin: com.vaadin.external.gwt/gwt-user
if ("body".equals(StringCase.toLower(getElement().getNodeName()))) {
return;
内容来源于网络,如有侵权,请联系作者删除!