示例#1
0
 void rrToWire(DNSOutput out, Compression c, boolean canonical) {
   out.writeU8(0); /* version */
   out.writeU8(toLOCformat(size));
   out.writeU8(toLOCformat(hPrecision));
   out.writeU8(toLOCformat(vPrecision));
   out.writeU32(latitude);
   out.writeU32(longitude);
   out.writeU32(altitude);
 }
示例#2
0
 void rrToWire(DNSOutput out, Compression c, boolean canonical) {
   host.toWire(out, c, canonical);
   admin.toWire(out, c, canonical);
   out.writeU32(serial);
   out.writeU32(refresh);
   out.writeU32(retry);
   out.writeU32(expire);
   out.writeU32(minimum);
 }
 private void toWireCanonical(DNSOutput out, boolean noTTL) {
   name.toWireCanonical(out);
   out.writeU16(type);
   out.writeU16(dclass);
   if (noTTL) {
     out.writeU32(0);
   } else {
     out.writeU32(ttl);
   }
   int lengthPosition = out.current();
   out.writeU16(0); /* until we know better */
   rrToWire(out, null, true);
   int rrlength = out.current() - lengthPosition - 2;
   out.save();
   out.jump(lengthPosition);
   out.writeU16(rrlength);
   out.restore();
 }
 void toWire(DNSOutput out, int section, Compression c) {
   name.toWire(out, c);
   out.writeU16(type);
   out.writeU16(dclass);
   if (section == Section.QUESTION) return;
   out.writeU32(ttl);
   int lengthPosition = out.current();
   out.writeU16(0); /* until we know better */
   rrToWire(out, c, false);
   int rrlength = out.current() - lengthPosition - 2;
   out.save();
   out.jump(lengthPosition);
   out.writeU16(rrlength);
   out.restore();
 }
示例#5
0
 void rrToWire(DNSOutput out, Compression c, boolean canonical) {
   out.writeU32(((long) addr) & 0xFFFFFFFFL);
 }