Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use targed gml namespace if boundedBy/geometry is in gml namespace #1550

Merged
merged 2 commits into from
Nov 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -371,7 +371,9 @@ else if (pt instanceof EnvelopePropertyType) {
writeNilledElement(propName, attributes);
}
else {
writeStartElementWithNS(propName.getNamespaceURI(), propName.getLocalPart());
String namespaceURI = GMLSchemaInfoSet.isGMLNamespace(propName.getNamespaceURI()) ? gmlNs
: propName.getNamespaceURI();
writeStartElementWithNS(namespaceURI, propName.getLocalPart());
if (value != null) {
gmlStreamWriter.getGeometryWriter().exportEnvelope((Envelope) value);
}
Original file line number Diff line number Diff line change
@@ -119,6 +119,7 @@
import org.deegree.geometry.standard.curvesegments.AffinePlacement;
import org.deegree.gml.GMLStreamWriter;
import org.deegree.gml.commons.AbstractGMLObjectWriter;
import org.deegree.gml.schema.GMLSchemaInfoSet;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@@ -1533,7 +1534,7 @@ private void startGeometry(String localName, Geometry geometry)
throws XMLStreamException, UnknownCRSException, TransformationException {

GMLObjectType gmlType = geometry.getType();
if (gmlType == null) {
if (gmlType == null || GMLSchemaInfoSet.isGMLNamespace(gmlType.getName().getNamespaceURI())) {
writeStartElementWithNS(gmlNs, localName);
}
else {
Original file line number Diff line number Diff line change
@@ -1653,6 +1653,8 @@ NOTE: In BLOB mode, only spatial and feature id queries can be mapped to SQL
WHERE-constraints. All other kinds of filter conditions are performed in
memory. See <<anchor-filtering>> for more information.

IMPORTANT: It is not recommended to mix GML versions in BLOB mode: The GML versions supported by WFS should be limited to the GML version of the features in the FeatureStore. Currently it cannot be ensured, that geometries transformed to another GML version are valid against the schema.

==== Transactions and feature id generation

The mapping defined by a _<FeatureTypeMapping>_ element generally