<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to patches</title><link href="https://sourceforge.net/p/skaringa/patches/" rel="alternate"/><link href="https://sourceforge.net/p/skaringa/patches/feed.atom" rel="self"/><id>https://sourceforge.net/p/skaringa/patches/</id><updated>2003-07-29T17:52:00Z</updated><subtitle>Recent changes to patches</subtitle><entry><title>trivial improvment to getFieldsToSerialize</title><link href="https://sourceforge.net/p/skaringa/patches/8/" rel="alternate"/><published>2003-07-29T17:52:00Z</published><updated>2003-07-29T17:52:00Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.net5b2aa732f729adbb26f3fc2121dfbe516232539e</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Looking through the code to chase down a different&lt;br /&gt;
problem (that probably isn't in Skaringa) I noticed&lt;br /&gt;
that getFieldsToSerialize() could be improved a little,&lt;br /&gt;
and since it gets called a lot it might be worthwhile.&lt;br /&gt;
First, it can use an ArrayList instead of a Vector to&lt;br /&gt;
save the synchronization overhead, second it can use a&lt;br /&gt;
zero-element array as the parameter to toArray().&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>fast pipelined transformer</title><link href="https://sourceforge.net/p/skaringa/patches/7/" rel="alternate"/><published>2003-04-27T23:11:53Z</published><updated>2003-04-27T23:11:53Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.netade183af84def6ac61fe058176493959df43abae</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Here's some code that implements a SAX-pipelined&lt;br /&gt;
stripped down hot-rod version of ObjectTransformer.  It&lt;br /&gt;
takes an XSLT stylesheet in the constructor and caches&lt;br /&gt;
Templates so it only needs to prepare the stylesheet&lt;br /&gt;
once and can build Transformers quickly on a per-call&lt;br /&gt;
basis.  With Saxon it's about 2.5 times faster than&lt;br /&gt;
passing strings between Skaringa and XSLT; with Xalan&lt;br /&gt;
there's less of a difference.&lt;/p&gt;
&lt;p&gt;Not sure how to fit it into Skaringa since it doesn't&lt;br /&gt;
explicitly implement ObjectTransformer but I thought&lt;br /&gt;
that you might be interested in the code.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;
Toby&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>allow input of dates with no time part</title><link href="https://sourceforge.net/p/skaringa/patches/6/" rel="alternate"/><published>2003-03-06T23:22:25Z</published><updated>2003-03-06T23:22:25Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.net4d7e9f3e01cedd711b96a3d283ca5c4c6928feb8</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;this patch modifies Skaringa's date parser to allow it&lt;br /&gt;
to deserialize dates that have no time component, i.e.&lt;/p&gt;
&lt;p&gt;&amp;amp;lt;aDate xsi:type=&amp;amp;quot;xsd:date&amp;amp;quot;&amp;amp;gt;2003-04-01&amp;amp;lt;/aDate&amp;amp;gt;&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>add more xml data types</title><link href="https://sourceforge.net/p/skaringa/patches/5/" rel="alternate"/><published>2003-02-21T21:51:25Z</published><updated>2003-02-21T21:51:25Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.net6d3fb6a056adcf4a2c217e7630b7008289371489</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;This patch adds some additional XML data types to make&lt;br /&gt;
Skaringa more flexible at deserializing XML files that&lt;br /&gt;
it didn't create.&lt;/p&gt;
&lt;p&gt;Since Skaringa will never use these types for&lt;br /&gt;
serialization I added them to the _deserializers map&lt;br /&gt;
directly instead of calling addSerializer().  mk,&lt;br /&gt;
please let me know if this is a bad approach.&lt;br /&gt;
&lt;/p&gt;
&lt;p&gt;The patch modifes SerializerRegistry.java and&lt;br /&gt;
JavaXMLTestClass.java.  There's also a new file called&lt;br /&gt;
StrangeTypesObj.java which goes in the&lt;br /&gt;
com.skaringa.javaxml.test package.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>more descriptive eror messages</title><link href="https://sourceforge.net/p/skaringa/patches/4/" rel="alternate"/><published>2003-02-18T20:49:21Z</published><updated>2003-02-18T20:49:21Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.netf39d5bd7bd359e980638875016514d1fe46db008</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;We're using Skaringa for a purpose for which it might&lt;br /&gt;
not have been intended: deserializing from non-Skaringa&lt;br /&gt;
XML into Java objects.  We get an input message in some&lt;br /&gt;
strange format and then run it through XSLT to get XML&lt;br /&gt;
which Skaringa can push into our hand-coded Java&lt;br /&gt;
classes.  Skaringa works well for this - it's very fast.&lt;/p&gt;
&lt;p&gt;This patch gives better diagnostics when the types&lt;br /&gt;
specified in the input XML don't match the types in the&lt;br /&gt;
Java classes.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>support for java.util.Locale</title><link href="https://sourceforge.net/p/skaringa/patches/3/" rel="alternate"/><published>2003-01-17T19:17:26Z</published><updated>2003-01-17T19:17:26Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.netbff5d7b1793a0afa55ae1f537bbf619d5ee1a5c6</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Locale doesn't have a no-arg constructor so&lt;br /&gt;
ObjectSerializer stubs its toe when it tries to&lt;br /&gt;
instantiate it.  Here's code to explicitly handle Locale.&lt;/p&gt;
&lt;p&gt;Patch to unit tests and the serializer registry, new&lt;br /&gt;
serializer class for Locale.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>support for serializing exceptions</title><link href="https://sourceforge.net/p/skaringa/patches/2/" rel="alternate"/><published>2003-01-13T15:08:06Z</published><updated>2003-01-13T15:08:06Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.netfc4451cf82ef018fcbda387cccd42536816c9c6b</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I've seen problems where Skaringa gets into an infinite&lt;br /&gt;
recursion when it tries to marshal certain objects,&lt;br /&gt;
specifically Exception and descendants.  After some&lt;br /&gt;
investigation it appears that the problem is that the&lt;br /&gt;
&amp;amp;quot;cause&amp;amp;quot; of the exception is initialized by default to&lt;br /&gt;
itself, so when Skaringa goes to serialize the cause it&lt;br /&gt;
gets into an infinite recursion (well, not infinite,&lt;br /&gt;
only until the stack overflows).&lt;/p&gt;
&lt;p&gt;I'm not sure what the real solution is, but I've&lt;br /&gt;
implemented a work-around that seems to work well for&lt;br /&gt;
the cases that I've seen.  Since the circularity is one&lt;br /&gt;
object that references itself in one of its members we&lt;br /&gt;
can just check that the member that we're about to&lt;br /&gt;
marshal isn't &amp;amp;quot;self&amp;amp;quot;.  Granted, larger loops (a -&amp;amp;gt; b -&amp;amp;gt;&lt;br /&gt;
a) will still cause problems, but those loops would&lt;br /&gt;
involve a lot more code to check, and marshalling&lt;br /&gt;
Exception can be useful.&lt;/p&gt;
&lt;p&gt;This patch is:&lt;/p&gt;
&lt;p&gt;- a new Exception test file&lt;br /&gt;
src/com/skaringa/javaxml/test/ExceptionObj.java&lt;br /&gt;
- a patch to ObjectSerializer to check for  objects&lt;br /&gt;
that reference themselves&lt;br /&gt;
- a patch to the test cases&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>serializers for BigInteger, BigDecimal, </title><link href="https://sourceforge.net/p/skaringa/patches/1/" rel="alternate"/><published>2002-12-30T20:01:08Z</published><updated>2002-12-30T20:01:08Z</updated><author><name>toby cabot</name><uri>https://sourceforge.net/u/tcabot/</uri></author><id>https://sourceforge.nete5152315e1b19a729fa55d61c7b3d6f1125ad5da</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Here's a patch (and some source files) that adds&lt;br /&gt;
serializers for java.math.BigInteger,&lt;br /&gt;
java.math.BigDecimal, and java.util.Set.&lt;/p&gt;
&lt;p&gt;The java.math classes don't have zero-arg constructors&lt;br /&gt;
so they seem to make Skaringa unhappy when it tries to&lt;br /&gt;
unmarshal them.  Set, too causes problems in&lt;br /&gt;
unmarshalling because a Set is not necessarily a&lt;br /&gt;
Collection.&lt;/p&gt;
&lt;p&gt;Note that the JavaXMLTestClass patch here depends on&lt;br /&gt;
the bug fixes that I submitted earlier, so you'll&lt;br /&gt;
probably want to apply those first.&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>