- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中org.deegree.commons.xml.stax.XMLStreamReaderWrapper.getSystemId()
方法的一些代码示例,展示了XMLStreamReaderWrapper.getSystemId()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XMLStreamReaderWrapper.getSystemId()
方法的具体详情如下:
包路径:org.deegree.commons.xml.stax.XMLStreamReaderWrapper
类名称:XMLStreamReaderWrapper
方法名:getSystemId
暂无
代码示例来源:origin: deegree/deegree3
/**
* @param xmlReader
*/
XMLErrorPosition( XMLStreamReader xmlReader ) {
if ( xmlReader instanceof XMLStreamReaderWrapper ) {
systemId = ( (XMLStreamReaderWrapper) xmlReader ).getSystemId();
} else {
systemId = "unknown source";
}
Location location = xmlReader.getLocation();
lineNumber = location.getLineNumber();
columnNumber = location.getColumnNumber();
characterOffset = location.getCharacterOffset();
}
代码示例来源:origin: deegree/deegree3
String schemaLocation = xmlStream.getAttributeValue( XSINS, "schemaLocation" );
if ( schemaLocation == null ) {
LOG.warn( Messages.getMessage( "NO_SCHEMA_LOCATION", xmlStream.getSystemId() ) );
return new DynamicAppSchema();
LOG.warn( Messages.getMessage( "ERROR_SCHEMA_LOCATION_TOKENS_COUNT", xmlStream.getSystemId() ) );
return new DynamicAppSchema();
String schemaUrl = tokens[i * 2 + 1];
try {
if ( xmlStream.getSystemId() == null ) {
schemaUrls[i] = new URL( new URL( xmlStream.getSystemId() ), schemaUrl ).toString();
LOG.warn( Messages.getMessage( "INVALID_SCHEMA_LOCATION", xmlStream.getSystemId() ) );
return new DynamicAppSchema();
schema = decoder.extractAppSchema();
} catch ( Throwable t ) {
LOG.warn( Messages.getMessage( "BROKEN_SCHEMA", xmlStream.getSystemId(), t.getMessage() ), t );
return new DynamicAppSchema();
代码示例来源:origin: deegree/deegree3
GMLReference<TimeSlice> refObject = null;
if ( specialResolver != null ) {
refObject = new GMLReference<TimeSlice>( specialResolver, href, xmlStream.getSystemId() );
} else {
refObject = new GMLReference<TimeSlice>( idContext, href, xmlStream.getSystemId() );
代码示例来源:origin: deegree/deegree3
private Geometry parseGeometryProperty( XMLStreamReaderWrapper xmlStream, ICRS crs )
throws XMLStreamException {
Geometry geometry = null;
String href = xmlStream.getAttributeValue( CommonNamespaces.XLNNS, "href" );
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
geometry = new GeometryReference<Geometry>( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) geometry );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
String msg = "Unexpected element '" + xmlStream.getName()
+ "'. Geometry value has already been specified using xlink.";
throw new XMLParsingException( xmlStream, msg );
}
} else if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
geometry = parse( xmlStream, crs );
xmlStream.nextTag();
} else {
String msg = "Error in geometry property element. Expected a 'gml:_Geometry' element or an 'xlink:href' attribute.";
throw new XMLParsingException( xmlStream, msg );
}
return geometry;
}
代码示例来源:origin: deegree/deegree3
private Polygon parsePolygonProperty( XMLStreamReaderWrapper xmlStream, ICRS crs )
throws XMLStreamException {
Polygon polygon = null;
String href = xmlStream.getAttributeValue( CommonNamespaces.XLNNS, "href" );
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
polygon = new PolygonReference( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) polygon );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
String msg = "Unexpected element '" + xmlStream.getName()
+ "'. Polygon value has already been specified using xlink.";
throw new XMLParsingException( xmlStream, msg );
}
} else if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
// must be a 'gml:Polygon' element
if ( !xmlStream.getLocalName().equals( "Polygon" ) ) {
String msg = "Error in polygon property element. Expected a 'gml:Polygon' element.";
throw new XMLParsingException( xmlStream, msg );
}
polygon = parsePolygon( xmlStream, crs );
xmlStream.nextTag();
} else {
String msg = "Error in Polygon property element. Expected a 'gml:Polygon' element or an 'xlink:href' attribute.";
throw new XMLParsingException( xmlStream, msg );
}
return polygon;
}
代码示例来源:origin: deegree/deegree3
private Point parsePointProperty( XMLStreamReaderWrapper xmlStream, ICRS crs )
throws XMLStreamException {
Point point = null;
String href = xmlStream.getAttributeValue( CommonNamespaces.XLNNS, "href" );
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
point = new PointReference( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) point );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
String msg = "Unexpected element '" + xmlStream.getName()
+ "'. Point value has already been specified using xlink.";
throw new XMLParsingException( xmlStream, msg );
}
} else if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
// must be a 'gml:Point' element
if ( !xmlStream.getLocalName().equals( "Point" ) ) {
String msg = "Error in point property element. Expected a 'gml:Point' element.";
throw new XMLParsingException( xmlStream, msg );
}
point = parsePoint( xmlStream, crs );
xmlStream.nextTag();
} else {
String msg = "Error in point property element. Expected a 'gml:Point' element or an 'xlink:href' attribute.";
throw new XMLParsingException( xmlStream, msg );
}
return point;
}
代码示例来源:origin: deegree/deegree3
private LineString parseLineStringProperty( XMLStreamReaderWrapper xmlStream, ICRS crs )
throws XMLStreamException {
LineString lineString = null;
String href = xmlStream.getAttributeValue( CommonNamespaces.XLNNS, "href" );
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
lineString = new LineStringReference( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) lineString );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
String msg = "Unexpected element '" + xmlStream.getName()
+ "'. LineString value has already been specified using xlink.";
throw new XMLParsingException( xmlStream, msg );
}
} else if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
// must be a 'gml:LineString' element
if ( !xmlStream.getLocalName().equals( "LineString" ) ) {
String msg = "Error in LineString property element. Expected a 'gml:LineString' element.";
throw new XMLParsingException( xmlStream, msg );
}
lineString = parseLineString( xmlStream, crs );
xmlStream.nextTag();
} else {
String msg = "Error in LineString property element. Expected a 'gml:LineString' element or an 'xlink:href' attribute.";
throw new XMLParsingException( xmlStream, msg );
}
return lineString;
}
代码示例来源:origin: deegree/deegree3
if ( specialResolver != null ) {
if( internalResolver == null ) {
refFeature = new FeatureReference( specialResolver, href, xmlStream.getSystemId() );
} else {
refFeature = new FeatureReference( specialResolver, internalResolver, href, xmlStream.getSystemId() );
refFeature = new FeatureReference( idContext, href, xmlStream.getSystemId() );
} else {
refFeature = new FeatureReference( idContext, internalResolver, href, xmlStream.getSystemId() );
代码示例来源:origin: deegree/deegree3
FeatureReference refFeature = null;
if ( specialResolver != null ) {
refFeature = new FeatureReference( specialResolver, href, xmlStream.getSystemId() );
} else {
refFeature = new FeatureReference( idContext, href, xmlStream.getSystemId() );
代码示例来源:origin: deegree/deegree3
if ( specialResolver != null ) {
ref = new TimeGeometricPrimitiveReference<TimeGeometricPrimitive>( specialResolver, href,
xmlStream.getSystemId() );
} else {
ref = new TimeGeometricPrimitiveReference<TimeGeometricPrimitive>( idContext, href,
xmlStream.getSystemId() );
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
primitive = new GeometricPrimitiveReference<GeometricPrimitive>( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) primitive );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
geometry = new GeometryReference<Geometry>( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) geometry );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
surface = new SurfaceReference<Surface>( getResolver(), href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) surface );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
solid = new SolidReference<Solid>( idContext, href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) solid );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
curve = new CurveReference<Curve>( getResolver(), href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) curve );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
point = new PointReference( getResolver(), href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) point );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
polygon = new PolygonReference( getResolver(), href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) polygon );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
if ( href != null && href.length() > 0 ) {
LOG.debug( "Found geometry reference (xlink): '" + href + "'" );
lineString = new LineStringReference( getResolver(), href, xmlStream.getSystemId() );
idContext.addReference( (GeometryReference<?>) lineString );
if ( xmlStream.nextTag() == XMLStreamConstants.START_ELEMENT ) {
代码示例来源:origin: deegree/deegree3
refGeometry = new GeometryReference<Geometry>( specialResolver, href, xmlStream.getSystemId() );
} else {
refGeometry = new GeometryReference<Geometry>( idContext, href, xmlStream.getSystemId() );
我知道使用sax时可以验证xml文件。但是我可以在使用Stax时进行验证吗? 最佳答案 SAX和DOM有两种XML验证方式: 单独验证-通过Validator.validate() 在解析期间验证-通
我在类路径中有一个 woodstox 和 java SE 1.6 stax 解析器,但默认情况下似乎选择了 woodstox。 但是在某些情况下,我想使用默认的 Java stax 解析器。有没有办法
我正面临 Woodstox STAX 和 java 1.6 STAX 实现之间奇怪的运行时冲突。由于我使用的是 CXF,它会将 Woodstox jar 作为其依赖项的一部分。这是我正在使用的示例代码
我正在尝试将一些代码从使用 DOM(通过 jDOM)转换为使用 StAX。同时,我正在从基于 DTD 的验证迁移到基于 XSD 的验证。哦,为了更好的衡量,我将 JAXB 引入等式 :) 无论如何,作
我不知道如何提取 XML 文件中的开始标记元素名称。我很接近〜意味着没有错误,我正在获取标签名称,但我正在获取标签名称加上信息。我得到的是: {http://www.publishing.org}au
对于下面发布的 xml 文件,我正在使用 StAX 来处理它。我写了下面的代码,但我不知道为什么尽管 xml 文件中有属性,但没有打印有关属性的信息。我希望控制台显示有关“id”、“lat”和“lon
我正在使用 StAX 来处理巨大的 xml 文件。如下面的代码所示,在 switch-case 中有一个默认条件。当我运行代码时默认情况下的文本打印以下内容: unhandled case4 case
我正在尝试使用 stax 从下面的 xml 中获取父项,请注意,同一结构中可以有多个父项和子项。 PARENT-CODE-1 PARENT-NAME-1
我有一个 xml <RPTSVC role:instanceID="765002" role:roleName="Re
是否有可能/是否有一种简单的方法可以找到与 START_ELEMENT 相对应的结束标记 (END_ELEMENT),如下所示? while(reader.hasNext()){ XM
我有以下(测试)XML 文件和使用 StaX 的 Java 代码。我想将此代码应用于大约 30 GB 大但元素相当小的文件,所以我认为 StaX 是一个不错的选择。我收到以下错误: 线程“main”中
我正在使用 java stax XMLStreamReader 来读取 xml。我想抓取某些内部节点的整个字符串。 XML: 我只想能够
我一直在尝试使用 StAX 创建一个 XML Controller 类。我的问题是我没有得到一个元素的完整字符串,而是得到了字符串的一小部分。 (请注意,出于安全原因,某些内容已被隐藏,这些内容将显示
我使用的是 java 6,rt.jar 具有进行基于 STaX 的解析所需的所有类。我主要使用以下类: import javax.xml.stream.XMLEventReader; import j
我正在使用 STAX 事件 API 读取从 SOAP 调用接收到的二进制数据,并希望将其流式传输给使用者。 SOAP 调用的 XML 有效负载如下所示: ......... PHNvY
我在来自 http://stax.codehaus.org/ 的 vrsion 1.2.0 中使用 StAX Streaming Api .当我尝试将以下 xml 写入文件时,不会转义大于 char
我正在使用以下简单的 StAX 代码循环访问 XML 中的所有标记。尺寸input.xml > 100 MB XMLInputFactory xif = XMLInputFactory.newInst
我正在读取与下面相同的 XML 文件: 我希望下面的代码打印出三个 e在屏幕上: XMLInputFactory factory = XMLInputFact
我有以下代码: XMLInputFactory inputFactory = XMLInputFactory.newInstance(); XMLStreamReader xmlStreamReade
我知道如何利用 java stax iterator api 来读取 xml 文档,但我想了解 XMLEvent 和 XMLEventReader 的实现。 XMLInputFactory xmlIn
我是一名优秀的程序员,十分优秀!