[Top][All Lists]

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

[DotGNU]DotGNU.IO.Records , BinaryReader and Endianess

From: Gopal V
Subject: [DotGNU]DotGNU.IO.Records , BinaryReader and Endianess
Date: Sun, 28 Jul 2002 13:14:18 +0530
User-agent: Mutt/1.2.5i

Hi Everyone,
        I have been taking a good long look at what Peter Minten wants
with the reading of binary records into a (class or struct) .. I 
realized that it couldn't be portable and work between C & C# ...

The System.IO.BinaryReader uses the native platform's endianess and 
has this issue that records written on GNU/Linux might not be readable
on Cygwin/Win32 . The current implementation is ideal for reading 
data by C programs (fwrite/fread) , but falls short of the idea of 
a portable binary record handler...

We'll have to use another BinaryWriter/Reader if we want to Serialize
portably between the platforms ?. Also do we need to maintain portability
for BinaryFormatter with .NET SDK ? (no documentation). 

The possibility of a new constructor for BitConvertor , one which specifies
the endianess rather than get it from the InternalCall ?. (will solve the
above issue)

A few ideas for newbies...

The difference between insanity and genius is measured by success

reply via email to

[Prev in Thread] Current Thread [Next in Thread]