Hello,
we are using our own schema to define the geometry attributes and to encode it
(using geotools 2.5.8) in this way:
Configuration configuration = new ApplicationSchemaConfiguration(namespace,
schema_location.toExternalForm());
org.geotools.xml.Encoder encoder = new org.geotools.xml.Encoder( configuration
);
OutputStream out = new FileOutputStream(new File(path));
encoder.encode(geometry, new QName( ourNamespace, "Geometry"), out);
And getting the exception:
Could not find elmeent declaration for:{ourNamespace}Geometry
If we encode an instance of the featurecollection
encoder.encode(featureCollection, new QName( ourNamespace,
"FeatureCollection"), out);
we get the warning:
org.geotools.xml.impl.GetPropertyExecutor visit
WARNING: org.geotools.feature.defaultfeaturecollect...@13c2ac3
(org.geotools.feature.DefaultFeatureCollection) is not of type
[Lorg.opengis.feature.simple.SimpleFeature;
And the encoded Geometry attribute is empty for all features of the encoded
FeatureCollection.
Other attributes (which are defined as <xs:simplyType> in our schema) are
encoded properly.
What could be a problem?
Do we need to use the ComplexBinding for the encoding of the attributes of the
complexType.
Could you give us a short example?
Many thanks for your help!
Anna
Kind regards,
Anna Pitaev
_________________________________________
Logica - Releasing your potential
Logica Deutschland GmbH & Co. KG
Rheinstrasse 95
64295 Darmstadt
Germany
Tel.: +49 6151 36860-121
E-Mail: anna.pit...@logica.com
www.logica.com
Logica Deutschland GmbH & Co. KG
Zettachring 4, 70567 Stuttgart; Amtsgericht Stuttgart HRA 722072
Persönlich haftender Gesellschafter: Logica Verwaltungs GmbH
Geschäftsführer: Torsten Straß (Vors.) / Dr. Thomas Elsner / Eric Guyot /
Andreas Manganaro / Olaf Scholz / Oliver Starzonek; Handelsregister AG
Stuttgart HRB 724084
Please help Logica to respect the environment by not printing this email /
Pour contribuer comme Logica au respect de l'environnement, merci de ne pas
imprimer ce mail / Bitte drucken Sie diese Nachricht nicht aus und helfen Sie
so Logica dabei, die Umwelt zu schützen. / Por favor ajude a Logica a
respeitar o ambiente nao imprimindo este correio electronico.
This e-mail and any attachment is for authorised use by the intended
recipient(s) only. It may contain proprietary material, confidential
information and/or be subject to legal privilege. It should not be copied,
disclosed to, retained or used by, any other party. If you are not an intended
recipient then please promptly delete this e-mail and any attachment and all
copies and inform the sender. Thank you.
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
Geotools-gt2-users mailing list
Geotools-gt2-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users