예제 #1
0
        public static void Restore(DVector <short> vec, BinaryReader reader)
        {
            int N = reader.ReadInt32();

            byte[]  bytes  = reader.ReadBytes(N * sizeof(short));
            short[] buffer = new short[N];
            Buffer.BlockCopy(bytes, 0, buffer, 0, bytes.Length);
            vec.Initialize(buffer);
        }