public void Load(BinaryReader reader, Action <int, long> values, int count)
        {
            if (reader.ReadByte() != VERSION)
            {
                throw new Exception("Invalid Int64IndexerPersist version.");
            }

            long factor = (long)CountCompression.Deserialize(reader);

            DeltaCompression.Decompress(reader, (idx, val) => values(idx, factor * val), count);
        }
        public void Load(BinaryReader reader, Action <int, decimal> values, int count)
        {
            if (reader.ReadByte() != VERSION)
            {
                throw new Exception("Invalid DecimalIndexerPersist version.");
            }

            int digits = reader.ReadSByte();

            if (digits >= 0)
            {
                double koef = Math.Pow(10, digits);
                DeltaCompression.Decompress(reader, (idx, val) => values(idx, (decimal)Math.Round(val / koef, digits)), count);
            }
            else //native read
            {
                for (int i = 0; i < count; i++)
                {
                    values(i, reader.ReadDecimal());
                }
            }
        }