- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中com.helger.xml.XMLHelper.getOwnerDocument()
方法的一些代码示例,展示了XMLHelper.getOwnerDocument()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XMLHelper.getOwnerDocument()
方法的具体详情如下:
包路径:com.helger.xml.XMLHelper
类名称:XMLHelper
方法名:getOwnerDocument
[英]Get the owner document of the passed node. If the node itself is a document, only a cast is performed.
[中]获取所传递节点的所有者文档。如果节点本身是文档,则只执行强制转换。
代码示例来源:origin: com.helger/ph-xml
@Nullable
public static Element getDocumentElement (@Nullable final Node aNode)
{
final Document aDoc = getOwnerDocument (aNode);
return aDoc == null ? null : aDoc.getDocumentElement ();
}
代码示例来源:origin: com.helger/ph-bdve
/**
* Create a complete validation source from an existing DOM node.
*
* @param sSystemID
* System ID to use. May be <code>null</code>.
* @param aNode
* The node to use. May not be <code>null</code>.
* @return Never <code>null</code>.
*/
@Nonnull
public static ValidationSource create (@Nullable final String sSystemID, @Nonnull final Node aNode)
{
ValueEnforcer.notNull (aNode, "Node");
// Use the owner Document as fixed node
return new ValidationSource (sSystemID, XMLHelper.getOwnerDocument (aNode), false);
}
代码示例来源:origin: com.helger/ph-schematron
public static <T> T evaluate (@Nonnull final XPathExpression aXPath,
@Nonnull final Node aItem,
@Nonnull final QName aReturnType,
@Nullable final String sBaseURI) throws XPathExpressionException
{
Object aRealItem = aItem;
if (sBaseURI != null && "net.sf.saxon.xpath.XPathExpressionImpl".equals (aXPath.getClass ().getName ()))
{
// Saxon specific handling
// This is trick needed for #47 - "base-uri()"
final XPathExpressionImpl aImpl = (XPathExpressionImpl) aXPath;
aRealItem = new DocumentWrapper (XMLHelper.getOwnerDocument (aItem),
sBaseURI,
aImpl.getConfiguration ()).wrap (aItem);
}
return GenericReflection.uncheckedCast (aXPath.evaluate (aRealItem, aReturnType));
}
}
代码示例来源:origin: phax/ph-schematron
public static <T> T evaluate (@Nonnull final XPathExpression aXPath,
@Nonnull final Node aItem,
@Nonnull final QName aReturnType,
@Nullable final String sBaseURI) throws XPathExpressionException
{
Object aRealItem = aItem;
if (sBaseURI != null && "net.sf.saxon.xpath.XPathExpressionImpl".equals (aXPath.getClass ().getName ()))
{
// Saxon specific handling
// This is trick needed for #47 - "base-uri()"
final XPathExpressionImpl aImpl = (XPathExpressionImpl) aXPath;
aRealItem = new DocumentWrapper (XMLHelper.getOwnerDocument (aItem),
sBaseURI,
aImpl.getConfiguration ()).wrap (aItem);
}
return GenericReflection.uncheckedCast (aXPath.evaluate (aRealItem, aReturnType));
}
}
代码示例来源:origin: com.helger/ph-xml
final Document aParentDoc = getOwnerDocument (aParentNode);
if (getOwnerDocument (aChildNode).equals (aParentDoc))
aParentNode.appendChild (getOwnerDocument (aParentNode).createTextNode ((String) aChild));
代码示例来源:origin: com.helger/ph-bdve
/**
* @return This validation source as a `javax.xml.transform.Source`. Never
* <code>null</code>.
* @throws IllegalStateException
* If no transform source object can be created.
*/
@Nonnull
default Source getAsTransformSource ()
{
Source ret = null;
final Node aNode = getNode ();
if (aNode != null)
{
if (isPartialSource ())
ret = TransformSourceFactory.create (aNode);
else
{
// Always use the Document node! Otherwise this may lead to weird XSLT
// errors
ret = TransformSourceFactory.create (XMLHelper.getOwnerDocument (aNode));
}
}
if (ret == null)
throw new IllegalStateException ("No valid input object is present!");
ret.setSystemId (getSystemID ());
return ret;
}
}
代码示例来源:origin: com.helger/ph-bdve
XMLHelper.getOwnerDocument (aNode));
if (aResult != null && !aResult.booleanValue ())
本文整理了Java中com.helger.xml.XMLHelper类的一些代码示例,展示了XMLHelper类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等
本文整理了Java中com.helger.xml.XMLHelper.getOwnerDocument()方法的一些代码示例,展示了XMLHelper.getOwnerDocument()的具体用法。
本文整理了Java中com.helger.xml.XMLHelper.getPathToNode2()方法的一些代码示例,展示了XMLHelper.getPathToNode2()的具体用法。这些代码
本文整理了Java中com.helger.xml.XMLHelper.filterElementWithNamespaceAndLocalName()方法的一些代码示例,展示了XMLHelper.fi
本文整理了Java中com.helger.xml.XMLHelper.getChildElementIterator()方法的一些代码示例,展示了XMLHelper.getChildElementIt
本文整理了Java中com.helger.xml.XMLHelper.forAllAttributes()方法的一些代码示例,展示了XMLHelper.forAllAttributes()的具体用法。
本文整理了Java中com.helger.xml.XMLHelper.getFirstChildElementOfName()方法的一些代码示例,展示了XMLHelper.getFirstChildE
我是一名优秀的程序员,十分优秀!