Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Arbitrary content (including XML) as binary stream

2 views
Skip to first unread message

Generic Usenet Account

unread,
Mar 24, 2009, 7:03:32 PM3/24/09
to
Hi,

In a certain Client/Server setup the following data-types are
supported:
binary, b64-encoded binary, boolean, char, int, float, date and xml.

As can be seen, the "Any" data type is not supported.

Each message exchanged between the client and the server has a
specific data-type. I am planning to "emulate" the Any data type in
this setup by trying to use the binary data type in lieu of Any, since
binary stream is the most fundamental of all data types. Are there
any issues I can run into? Someone told me that the encoding scheme
used in XML (ASCII, UTF-8, Unicode etc.) will give me some grief but I
don't fully comprehend the issue. After all, at a certain level
everything reduces to bits and bytes.

Any insight will be appreciated.

Thanks,
Ramesh

cr88192

unread,
Mar 25, 2009, 4:47:48 AM3/25/09
to

"Generic Usenet Account" <use...@sta.samsung.com> wrote in message
news:3d194fbd-fb86-4929...@w35g2000yqm.googlegroups.com...

it will likely be needed to indicate which representation is used
per-message, and thus likely require defining a protocol in itself (raw data
is too vague. yes, anything can be sent as raw data, but it is not nearly so
useful unless you know which format it is).

but, alas, if the protocol already has a way of indicating which it is,
there is no problem.

if you mean, you have a raw-binary chunk as a possible message type, and
want to run other types through it, one possibility is to add a small tag to
the front of the data, such as a FOURCC or similar (may be optional for
formats which can self-identify via their headers, ...).

example, an XML chunk could have 'XML ' followed by any XML data (although,
granted, officially one can identify XML payloads via "<?xml ...", but alas
in practice it is not so common that every piece of XML starts with such a
signtature tag...).

> Thanks,
> Ramesh


0 new messages