Re: [Fwd: Re: [xml] hexBinary schema datatype patch]



On Mon, Jul 07, 2003 at 08:14:12PM -0500, Charles Bozeman wrote:
On Mon, 2003-07-07 at 04:12, Peter Sobisch wrote:

Hi guys,

I have a question about hexBinary-implemantation from Charles:
why is the hexBinary restricted to 12 bytes ?

Purely for pragmatic reasons. I reused the same structure that is used
for decimal (and it's derived types) which has 3 long ints for storing
the value.

   maybe we need to allocate a new string (if the value is needed).

I suppose a better implementation would be to store copies of the
hexBinary strings representations instead of converting them to values.
I think it is doable but I don't know when I will have time.

  yeah, but that part isn't clear yet. I don't know how to store the
values in the tree when a document has been validated. I was toying with
the idea of defining a new node type and store it in the children list
of the element or the attribute as the predecessor of node->children

             Node
              | children
              v
   TYPE <-> fist child <-> second child ... <-> last child

  That would allow adding PSVI while minimizing the impact on the code
base but I really can't consider this a clean solution. The only other
possibility would be to extend the elements and attributes nodes with
a PSVI field, it's somewhat more clean, but I can't say I like the idea
of changing node size either.

Daniel

-- 
Daniel Veillard      | Red Hat Network https://rhn.redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]