热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

org.deegree.commons.xml.XPath.()方法的使用及代码示例

本文整理了Java中org.deegree.commons.xml.XPath.<init>()方法的一些代码示例,展示了XPath.<i

本文整理了Java中org.deegree.commons.xml.XPath.()方法的一些代码示例,展示了XPath.()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XPath.()方法的具体详情如下:
包路径:org.deegree.commons.xml.XPath
类名称:XPath
方法名:

XPath.介绍

暂无

代码示例

代码示例来源:origin: deegree/deegree3

private BBoxOutputType parseBBoxOutput( OMElement bboxData, CodeType id, LanguageString outputTitle,
LanguageString outputAbstract ) {
XPath xpath = new XPath( "Default/CRS", nsContext );
String defaultCrs = omResponse.getElement( bboxData, xpath ).getText();
xpath = new XPath( "Supported/CRS", nsContext );
List omSupported = omResponse.getElements( bboxData, xpath );
String[] supportedCrs = new String[omSupported.size()];
for ( int i = 0; i supportedCrs[i] = omSupported.get( i ).getText();
}
return new BBoxOutputType( id, outputTitle, outputAbstract, defaultCrs, supportedCrs );
}

代码示例来源:origin: deegree/deegree3

private BBoxInputType parseBBoxData( OMElement input, CodeType id, LanguageString inputTitle,
LanguageString inputAbstract, String minOccurs, String maxOccurs ) {
XPath xpath = new XPath( "Default/CRS", nsContext );
String defaultCRS = omResponse.getElement( input, xpath ).getText();
xpath = new XPath( "Supported/CRS", nsContext );
List omSupported = omResponse.getElements( input, xpath );
String[] supportedCRSs = new String[omSupported.size()];
for ( int i = 0; i supportedCRSs[i] = omSupported.get( i ).getText();
}
return new BBoxInputType( id, inputTitle, inputAbstract, minOccurs, maxOccurs, defaultCRS, supportedCRSs );
}

代码示例来源:origin: deegree/deegree3

@Override
public List parseFeatureTypeList() {
List ftEls = getElements( rootElement, new XPath( "wfs:FeatureTypeList/wfs:FeatureType", nsContext ) );
List fts = new ArrayList( ftEls.size() );
for ( OMElement ftEl : ftEls ) {
fts.add( parseFeatureType( ftEl ) );
}
return fts;
}

代码示例来源:origin: deegree/deegree3

@Override
public List parseFeatureTypeList() {
List ftEls = getElements( rootElement, new XPath( "wfs:FeatureTypeList/wfs:FeatureType", nsContext ) );
List fts = new ArrayList( ftEls.size() );
for ( OMElement ftEl : ftEls ) {
fts.add( parseFeatureType( ftEl ) );
}
return fts;
}

代码示例来源:origin: deegree/deegree3

private List> parseIdentifiers( OMElement lay ) {
List> identifiers = new ArrayList>();
List identiferElements = getElements( lay, new XPath( getPrefix() + "Identifier", nsContext ) );
for ( OMElement identifierElement : identiferElements ) {
String id = identifierElement.getText();
if ( id != null && id.length() > 0 ) {
String authority = getNodeAsString( identifierElement, new XPath( "@authority" ), null );
identifiers.add( new Pair( id, authority ) );
}
}
return identifiers;
}

代码示例来源:origin: deegree/deegree3

private List> parseAuthorities( OMElement lay ) {
List> authorities = new ArrayList>();
List authorityElements = getElements( lay, new XPath( getPrefix() + "AuthorityURL", nsContext ) );
for ( OMElement authorityElement : authorityElements ) {
String authority = getNodeAsString( authorityElement, new XPath( "@name" ), null );
String authorityUrl = getNodeAsString( authorityElement, new XPath( getPrefix()
+ "OnlineResource/@xlink:href",
nsContext ), null );
authorities.add( new Pair( authority, authorityUrl ) );
}
return authorities;
}

代码示例来源:origin: deegree/deegree3

@Override
public void serialize( XMLStreamWriter writer, String[] elementNames )
throws XMLStreamException {
List xpathEN = new ArrayList();
for ( String s : elementNames ) {
xpathEN.add( new XPath( s, CommonNamespaces.getNamespaceContext() ) );
}
if ( !xpathEN.isEmpty() ) {
writer = new FilteringXMLStreamWriter( writer, xpathEN );
}
root.serialize( writer );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the id
*/
public String getId() {
return adapter.getRequiredNodeAsString( adapter.getRootElement(), new XPath( "./@id", ns ) );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the extId
*/
public String getExtId() {
return adapter.getNodeAsString( adapter.getRootElement(),
new XPath( "./rim:ExternalIdentifier/rim:Name/rim:LocalizedString/@value", ns ),
null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the queryExpression
*/
public OMElement getQueryExpression() {
return adapter.getElement( adapter.getRootElement(), new XPath( "./rim:QueryExpression", ns ) );
}

代码示例来源:origin: deegree/deegree3

private static String retrieveLiteral( OMElement value ) {
XMLAdapter adapter = new XMLAdapter();
XPath xpath = new XPath( "//" + FES_PREFIX + ":Literal", NS_CONTEXT );
return adapter.getNodeAsString( value, xpath, null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the desc
*/
public String getDesc() {
return adapter.getNodeAsString( adapter.getRootElement(),
new XPath( "./rim:Description/rim:LocalizedString/@value", ns ), null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the home
*/
public String getHome() {
return adapter.getNodeAsString( adapter.getRootElement(), new XPath( "./@home", ns ), null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the status
*/
public String getStatus() {
return adapter.getNodeAsString( adapter.getRootElement(), new XPath( "./@status", ns ), null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the targetObject
*/
public String getTargetObject() {
return adapter.getRequiredNodeAsString( adapter.getRootElement(), new XPath( "@targetObject", ns ) );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the parent
*/
public String getParent() {
return adapter.getNodeAsString( adapter.getRootElement(), new XPath( "./@parent", ns ), null );
}

代码示例来源:origin: deegree/deegree3

/**
* @return the code
*/
public String getCode() {
return adapter.getNodeAsString( adapter.getRootElement(), new XPath( "./@code", ns ), null );
}

代码示例来源:origin: deegree/deegree3

private String parseOutputFormat()
throws OWSException {
String format = getNodeAsString( rootElement, new XPath( "/" + WCS_PREFIX + ":GetCoverage/" + WCS_PREFIX
+ ":output/" + WCS_PREFIX + ":format", wcsNSContext ),
null );
checkRequiredString( "format", format );
return format;
}

代码示例来源:origin: deegree/deegree3

/**
* @return a {@link OWSCapabilities} instance, never null
*/
public OWSCapabilities parseMetadata() {
Version version = getNodeAsVersion( rootElement, new XPath( "@version", nsContext ), null );
String sequence = getNodeAsString( rootElement, new XPath( "@updateSequence", nsContext ), null );
ServiceIdentification serviceId = parseServiceIdentification();
ServiceProvider serviceProvider = parseServiceProvider();
OperationsMetadata opMetadata = parseOperationsMetadata();
List languages = parseLanguages();
return new OWSCapabilities( version, sequence, serviceId, serviceProvider, opMetadata, languages );
}

代码示例来源:origin: deegree/deegree3

private QName determineTargetElementAdv( XMLAdapter annotationXML ) {
NamespaceBindings nsCOntext= new NamespaceBindings();
nsContext.addNamespace( "xs", CommonNamespaces.XSNS );
nsContext.addNamespace( "adv", "http://www.adv-online.de/nas" );
QName refElement = annotationXML.getNodeAsQName( annotationXML.getRootElement(),
new XPath( "xs:appinfo/adv:referenziertesElement/text()",
nsContext ), null );
if ( refElement != null ) {
LOG.trace( "Identified a target element annotation (adv style)." );
}
return refElement;
}

推荐阅读
  • 探讨ChatGPT在法律和版权方面的潜在风险及影响,分析其作为内容创造工具的合法性和合规性。 ... [详细]
  • 本文探讨了如何在Java中使用JAXB解组两个具有相同名称但不同结构的对象。我们将介绍一个抽象类Bar及其具体实现,并展示如何正确地解析XML文档以获取正确的对象实例。 ... [详细]
  • springMVC JRS303验证 ... [详细]
  • 深入解析Spring启动过程
    本文详细介绍了Spring框架的启动流程,帮助开发者理解其内部机制。通过具体示例和代码片段,解释了Bean定义、工厂类、读取器以及条件评估等关键概念,使读者能够更全面地掌握Spring的初始化过程。 ... [详细]
  • This post discusses an issue encountered while using the @name annotation in documentation generation, specifically regarding nested class processing and unexpected output. ... [详细]
  • ListView简单使用
    先上效果:主要实现了Listview的绑定和点击事件。项目资源结构如下:先创建一个动物类,用来装载数据:Animal类如下:packagecom.example.simplelis ... [详细]
  • 本文将详细探讨 Java 中提供的不可变集合(如 `Collections.unmodifiableXXX`)和同步集合(如 `Collections.synchronizedXXX`)的实现原理及使用方法,帮助开发者更好地理解和应用这些工具。 ... [详细]
  • 本文详细探讨了 PHP 中常见的 '未定义索引' 错误,包括其原因、解决方案及最佳实践。通过实例和代码片段,帮助开发者更好地理解和处理这一常见问题。 ... [详细]
  • 在尝试使用C# Windows Forms客户端通过SignalR连接到ASP.NET服务器时,遇到了内部服务器错误(500)。本文将详细探讨问题的原因及解决方案。 ... [详细]
  • Python + Pytest 接口自动化测试中 Token 关联登录的实现方法
    本文将深入探讨 Python 和 Pytest 在接口自动化测试中如何实现 Token 关联登录,内容详尽、逻辑清晰,旨在帮助读者掌握这一关键技能。 ... [详细]
  • 深入解析ESFramework中的AgileTcp组件
    本文详细介绍了ESFramework框架中AgileTcp组件的设计与实现。AgileTcp是ESFramework提供的ITcp接口的高效实现,旨在优化TCP通信的性能和结构清晰度。 ... [详细]
  • 本文介绍了 Python 的 Pmagick 库中用于图像处理的木炭滤镜方法,探讨其功能和用法,并通过实例演示如何应用该方法。 ... [详细]
  • ssm框架整合及工程分层1.先创建一个新的project1.1配置pom.xml ... [详细]
  • 本文探讨了如何在Classic ASP中实现与PHP的hash_hmac('SHA256', $message, pack('H*', $secret))函数等效的哈希生成方法。通过分析不同实现方式及其产生的差异,提供了一种使用Microsoft .NET Framework的解决方案。 ... [详细]
  • 主调|大侠_重温C++ ... [详细]
author-avatar
公民不是百姓2
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有