From lthota at yahoo.com Thu Jul 2 16:20:53 2009 From: lthota at yahoo.com (Laxmi Thota) Date: Thu Jul 2 16:21:01 2009 Subject: [xsde-users] XSD/e shared library Message-ID: <453361.83193.qm@web30303.mail.mud.yahoo.com> Hi Boris, Thanks for your response on XSD/e features. Currently XSD/e is available as a static library. Can it be compiled and used as shared library? Do you see any issues with it being used as a shared library. Is it thread safe? Thanks, Laxmi From boris at codesynthesis.com Thu Jul 2 21:52:41 2009 From: boris at codesynthesis.com (Boris Kolpackov) Date: Thu Jul 2 19:48:07 2009 Subject: [xsde-users] XSD/e shared library In-Reply-To: <453361.83193.qm@web30303.mail.mud.yahoo.com> References: <453361.83193.qm@web30303.mail.mud.yahoo.com> Message-ID: Hi Laxmi, Laxmi Thota writes: > Currently XSD/e is available as a static library. Can it be compiled > and used as shared library? There is no out of the box support for building the runtime as a shared library but it should be quite easy to add. You can add the necessary C++ compiler options (e.g., -fPIC) to CFLAGS and CXXFLAGS variables in config.make. Then you can replace the following lines in libxsde/xsde/makefile: libxsde.a: $(obj) $(AR) $(ARFLAGS) $@ $^ ifneq ($(RANLIB),) $(RANLIB) $@ endif With something like this: libxsde.so: $(obj) $(CXX) -shared -o $@ $^ > Do you see any issues with it being used as a shared library. No, there shouldn't be any problems. > Is it thread safe? The runtime library and generated code are thread-safe in the sense that you can use different instantiations of the parsers, serializers, and object models in several threads concurrently. This is possible because we do not relying on any writable global variables. If you need to share the same parser, serializer, or object model between several threads then you will need to provide some form of synchronization to make sure these objects are not accessed from more than one thread at a time. Boris From jblinten at gmail.com Thu Jul 9 14:38:46 2009 From: jblinten at gmail.com (Jerry Blinten) Date: Thu Jul 9 14:39:14 2009 Subject: [xsde-users] GML 3.2.1 Message-ID: <012001ca00c4$7f535c40$7dfa14c0$@com> I am working with a schema that requires OpenGIS GML 3.2.1 and have "hit the wall" with XSDe code generation. I have read the forum discussions on GML (http://wiki.codesynthesis.com/Schemas/GML and http://wiki.codesynthesis.com/Talk:Schemas/GML). Unfortunately, the discussion is a bit dated with references up to GML 3.1.1. It seems that the circular references are even deeper with 3.2.1. Has anyone successfully generated code from this schema or can offer any advice on the required steps? Thanks for your help & best regards, Jerry From boris at codesynthesis.com Thu Jul 9 21:04:50 2009 From: boris at codesynthesis.com (Boris Kolpackov) Date: Thu Jul 9 19:00:06 2009 Subject: [xsde-users] GML 3.2.1 In-Reply-To: <012001ca00c4$7f535c40$7dfa14c0$@com> References: <012001ca00c4$7f535c40$7dfa14c0$@com> Message-ID: Hi Jerry, Jerry Blinten writes: > Has anyone successfully generated code from this schema or can offer > any advice on the required steps? I was able to compile this schema in the file-per-type mode. For more information on this mode see this blog post (it talks about XSD but it works the same in XSD/e): http://www.codesynthesis.com/~boris/blog/2008/02/13/codesynthesis-xsd-3-1-0-released/ I also had to add a little bit of "syntactic sugar" to a few files to help XSD/e establish correspondence between particles in inheritance by restriction. We plan to address this in the next release of XSD/e so that these changes won't be necessary. The patch is available here: http://www.codesynthesis.com/~boris/tmp/gml-3.2.1-restrictions.patch Boris From MarkusK at microsol.ie Fri Jul 31 11:48:09 2009 From: MarkusK at microsol.ie (Markus Kohler) Date: Fri Jul 31 12:08:30 2009 Subject: [xsde-users] Extract remaining subtree Message-ID: <200907311648.09678.MarkusK@microsol.ie> Hello there, given a XML file and using the embedded parser xsde can I retrieve a certain part of the XML tree as string. Example: The xsde parser generates some class class someelement_pimpl ... { ... pre() {...} post_someelement() {...} subtree() {...} ... } Is there a possibility in pre() or post_someelement() or anywhere else to retrieve the XML string starting with until maybe through the context? Thanks in advance for any help! Markus Markus Kohler SW Engineer Microsol Dublin