LumiSoft.Net.Dns.Client.Dns_Client.ParseHINFORecord C# (CSharp) Method

ParseHINFORecord() private method

private ParseHINFORecord ( byte reply, int &offset, int rdLength, int ttl ) : HINFO_Record
reply byte
offset int
rdLength int
ttl int
return HINFO_Record
        private HINFO_Record ParseHINFORecord(byte[] reply,ref int offset,int rdLength,int ttl)
        {
            /* RFC 1035 3.3.2. HINFO RDATA format

            +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
            /                      CPU                      /
            +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
            /                       OS                      /
            +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+

            CPU     A <character-string> which specifies the CPU type.

            OS      A <character-string> which specifies the operating
                    system type.

                    Standard values for CPU and OS can be found in [RFC-1010].

            */

            // CPU
            string cpu = "";
            GetQName(reply,ref offset,ref cpu);

            // OS
            string os = "";
            GetQName(reply,ref offset,ref os);

            return new HINFO_Record(cpu,os,ttl);
        }