Esempio n. 1
0
 public Region(int regionId, byte[] start, byte[] end, RegionStat stat)
 {
     this.regionId = regionId;
     this.start    = start;
     this.end      = end;
     this.stat     = stat;
 }
Esempio n. 2
0
 public static RegionStat decodeRegionStat(KVMemoryStream stream)
 {
     RegionStat stat = new RegionStat();
     stat.keyNum = stream.ReadInt();
     stat.size = stream.ReadLong();
     stat.readCount = stream.ReadLong();
     stat.writeCount = stream.ReadLong();
     return stat;
 }
Esempio n. 3
0
        public static RegionStat decodeRegionStat(KVMemoryStream stream)
        {
            RegionStat stat = new RegionStat();

            stat.keyNum     = stream.ReadInt();
            stat.size       = stream.ReadLong();
            stat.readCount  = stream.ReadLong();
            stat.writeCount = stream.ReadLong();
            return(stat);
        }
Esempio n. 4
0
        public static Region decodeRegion(KVMemoryStream stream)
        {
            int regionId = stream.ReadInt();

            byte[]     start = stream.ReadBytes();
            byte[]     end   = stream.ReadBytes();
            RegionStat stat  = decodeRegionStat(stream);

            return(new Region(regionId, start, end, stat));
        }