Ejemplo n.º 1
0
        protected void Read(DataResponse response)
        {
            int count = 0;

            BinaryReader reader = response.Reader;

            if (response.Version >= NetworkProtocol.NETWORK_PROTOCOL_VERSION_24)
            {
                count   = reader.ReadInt32();
                Modules = new List <Module>(count);
                for (uint i = 0; i < count; ++i)
                {
                    Module module = new Module();
                    module.Path    = Utils.ReadBinaryString(reader);
                    module.Address = reader.ReadUInt64();
                    module.Size    = reader.ReadUInt64();
                    Modules.Add(module);
                }
                Modules.Sort();
            }

            count        = reader.ReadInt32();
            Descriptions = new Dictionary <UInt64, SamplingDescription>(count);
            for (uint i = 0; i < count; ++i)
            {
                SamplingDescription desc = SamplingDescription.Create(reader, response.Version);
                desc.Module = GetModule(desc.Address);
                Descriptions[desc.Address] = desc;
            }
        }
Ejemplo n.º 2
0
        protected void Read(BinaryReader reader)
        {
            Descriptions = new Dictionary <UInt64, SamplingDescription>();

            uint count = reader.ReadUInt32();

            for (uint i = 0; i < count; ++i)
            {
                SamplingDescription desc = SamplingDescription.Create(reader);
                Descriptions[desc.Address] = desc;
            }
        }
Ejemplo n.º 3
0
        public static SamplingDescriptionBoard Create(BinaryReader reader)
        {
            SamplingDescriptionBoard board = new SamplingDescriptionBoard();

            board.Descriptions = new Dictionary <UInt64, SamplingDescription>();

            uint count = reader.ReadUInt32();

            for (uint i = 0; i < count; ++i)
            {
                SamplingDescription desc = SamplingDescription.Create(reader);
                board.Descriptions[desc.Address] = desc;
            }

            return(board);
        }
Ejemplo n.º 4
0
 public override SamplingDescription GetDescription(ulong address)
 {
     return(SamplingDescription.Create(address));
 }