org.deegree.gml
Class XMLTransformer
java.lang.Object
org.deegree.cs.Transformer
org.deegree.geometry.GeometryTransformer
org.deegree.gml.XMLTransformer
public class XMLTransformer
- extends GeometryTransformer
The XMLTransformer
transforms any xml documents containing gml geometries. Only the geometries will be
transformed all other data (including comments and cdata) will be copied.
- Version:
- $Revision: 31619 $, $Date: 2011-08-23 14:56:28 +0200 (Tue, 23 Aug 2011) $
- Author:
- Rutger Bezema, last edited by: $Author: mschneider $
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLTransformer
public XMLTransformer(ICRS targetCRS)
throws IllegalArgumentException
- Parameters:
targetCRS
-
- Throws:
IllegalArgumentException
UnknownCRSException
XMLTransformer
public XMLTransformer(String targetCRS)
throws IllegalArgumentException,
UnknownCRSException
- Parameters:
targetCRS
-
- Throws:
IllegalArgumentException
UnknownCRSException
XMLTransformer
public XMLTransformer(Transformation transformation)
throws IllegalArgumentException
- Parameters:
transformation
-
- Throws:
IllegalArgumentException
transform
public void transform(XMLStreamReader reader,
XMLStreamWriter writer,
ICRS sourceCRS,
GMLVersion gmlVersion,
boolean testValidArea,
List<Transformation> requestedTransformation)
throws XMLStreamException,
XMLParsingException,
IllegalArgumentException,
OutsideCRSDomainException,
UnknownCRSException,
TransformationException
- Transforms the given input stream, and streams the input into the output directly. If a geometry is found, the
geometry is transformed into the target crs. All other events are just copied.
- Parameters:
reader
- an XMLStream containing some GML Geometries.writer
- the output will be written to this writer, the writer have been opened (
XMLStreamWriter.writeStartDocument()
. No XMLStreamWriter.writeEndDocument()
will be
written as well.sourceCRS
- to be used if the geometries do not define a srsName (or the like) attribute.gmlVersion
- the version of the expected geometries.testValidArea
- true if the incoming geometries should be checked against the valid domain of the crs they are defined
in.requestedTransformation
- can be null
- Throws:
XMLStreamException
XMLParsingException
IllegalArgumentException
OutsideCRSDomainException
UnknownCRSException
TransformationException
transform
public void transform(XMLStreamReader reader,
XMLStreamWriter writer,
GMLVersion gmlVersion)
throws XMLStreamException,
XMLParsingException,
IllegalArgumentException,
OutsideCRSDomainException,
UnknownCRSException,
TransformationException
- Transforms the given input stream, and streams the input into the output directly. If a geometry is found, the
geometry is transformed into the target crs. All other events are just copied.
- Parameters:
reader
- an XMLStream containing some GML Geometries.writer
- the output will be written to this writer, the writer have been opened (
XMLStreamWriter.writeStartDocument()
. No XMLStreamWriter.writeEndDocument()
will be
written as well.gmlVersion
- the version of the expected geometries.
- Throws:
XMLStreamException
XMLParsingException
IllegalArgumentException
OutsideCRSDomainException
UnknownCRSException
TransformationException
Copyright © 2011. All Rights Reserved.