[Expat-discuss] How can I add a function to skip a setnumber of bytes

Joe Wiemann jwieman@daktronics.com
Tue Sep 4 18:00:02 2001


this is for an embedded system where I plan to embed graphics into my file
format.

I can tell how many bytes I need to skip by the tag that proceeds the
graphic

ex.
here I skip 12 bytes

<IM h="2" w="6" bitcount="8">XxXxXxXxXxXx</IM>

the problem is that I can have the following in there too

<IM h="2" w="6" bitcount="8"><IM><>?? !^y</IM>

so I really need to just skip so many bytes -- and encoding will not
matter... it will still be skipping bytes in this case...

I know this is not following XML -- but I think I can get it to work -> I do
not want the overhead of doing mime encoding or anything like that.

I want to skip the bytes and parse normally after that.
----- Original Message -----
From: "David Crowley" <dcrowley@scitegic.com>
To: <expat-discuss@lists.sourceforge.net>
Sent: Tuesday, September 04, 2001 5:51 PM
Subject: RE: [Expat-discuss] How can I add a function to skip a setnumber of
bytes


> At 03:33 PM 9/4/2001, Joe Wiemann wrote:
> >how can I adjust the ptr where the parser is parsing from -- ie,  Move
the
> >ptr ahead a certain number of bytes without having to parse through those
> >bytes with the parser.
>
>
>
> You had better be careful what you ask for, because you just might get
> it.  What is your real requirement other than "skipping bytes?"   Why do
> you want to tell the parser how to deal with the the raw bytes instead of
> letting the parser deal with bytes and you just don't do anything in the
> callbacks that correspond to those bytes??  Bytes is a bad thing to skip
> too.  What happens when the document comes encoded in scheme such that 1
> byte != 1 char?  UTF-8, UTF-16, etc. come to mind...
>
>
> _______________________________________________
> Expat-discuss mailing list
> Expat-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/expat-discuss