[xsd-users] comparison operation

Boris Kolpackov boris at codesynthesis.com
Sun Aug 31 06:17:47 EDT 2008


Hi Ray,

Rizzuto, Raymond <Raymond.Rizzuto at sig.com> writes:
 
> I can't access the first URL - I get an "Object not found!| Message when
> I try.  I believe that is the same link as from your 3.2.0 beta1 release
> posting, and I did look at that 2 days ago, so maybe it will be back later.

Ok, I've removed 2 from www2 in all the places.


> I'm hoping I can set the precision to 6 places so that timestamps will
> round trip at the microsecond range.

On the second thought, perhaps it can work if the numbers you are 
trying to serialize are also rounded to this precision (that is, the
binary representation will have more digits but they will be the same).

Another alternative would be to compare string representations. For
example, you could defined the Timestamp type in XML Schema by deriving
from double. You would then customize this type and provide your own
comparison operator implementation which compares two Timestamps as
strings with precision 6. This will be slower but will work on all
platforms. 


> I'd be interested in reading the post about VC++ and round-trip for
> floats if you can find it.

It is this (long) thread on boost-devel:

http://lists.boost.org/Archives/boost/2006/03/101988.php


The posts of particular interest are:

http://lists.boost.org/Archives/boost/2006/04/102744.php 

http://lists.boost.org/Archives/boost/2006/04/102833.php


Boris




More information about the xsd-users mailing list