/** * Add a question to the message. * * @param out * outgoing message * @param rec * DNS question * @return outgoing message for the next question * @exception IOException */ public DNSOutgoing addQuestion(DNSOutgoing out, DNSQuestion rec) throws IOException { DNSOutgoing newOut = out; try { newOut.addQuestion(rec); } catch (final IOException e) { int flags = newOut.getFlags(); boolean multicast = newOut.isMulticast(); int maxUDPPayload = newOut.getMaxUDPPayload(); int id = newOut.getId(); newOut.setFlags(flags | DNSConstants.FLAGS_TC); newOut.setId(id); this._jmDNSImpl.send(newOut); newOut = new DNSOutgoing(flags, multicast, maxUDPPayload); newOut.addQuestion(rec); } return newOut; }
/** * Add a question to the message. * * @param out * outgoing message * @param rec * DNS question * @return outgoing message for the next question * @exception IOException */ public DNSOutgoing addQuestion(DNSOutgoing out, DNSQuestion rec) throws IOException { DNSOutgoing newOut = out; try { newOut.addQuestion(rec); } catch (final IOException e) { int flags = newOut.getFlags(); boolean multicast = newOut.isMulticast(); int maxUDPPayload = newOut.getMaxUDPPayload(); int id = newOut.getId(); newOut.setFlags(flags | DNSConstants.FLAGS_TC); newOut.setId(id); this._jmDNSImpl.send(newOut); newOut = new DNSOutgoing(flags, multicast, maxUDPPayload); newOut.addQuestion(rec); } return newOut; }
/** * Add a question to the message. * * @param out * outgoing message * @param rec * DNS question * @return outgoing message for the next question * @exception IOException */ public DNSOutgoing addQuestion(DNSOutgoing out, DNSQuestion rec) throws IOException { DNSOutgoing newOut = out; try { newOut.addQuestion(rec); } catch (final IOException e) { int flags = newOut.getFlags(); boolean multicast = newOut.isMulticast(); int maxUDPPayload = newOut.getMaxUDPPayload(); int id = newOut.getId(); newOut.setFlags(flags | DNSConstants.FLAGS_TC); newOut.setId(id); this._jmDNSImpl.send(newOut); newOut = new DNSOutgoing(flags, multicast, maxUDPPayload); newOut.addQuestion(rec); } return newOut; }
/** * Add a question to the message. * * @param out * outgoing message * @param rec * DNS question * @return outgoing message for the next question * @exception IOException */ public DNSOutgoing addQuestion(DNSOutgoing out, DNSQuestion rec) throws IOException { DNSOutgoing newOut = out; try { newOut.addQuestion(rec); } catch (final IOException e) { int flags = newOut.getFlags(); boolean multicast = newOut.isMulticast(); int maxUDPPayload = newOut.getMaxUDPPayload(); int id = newOut.getId(); newOut.setFlags(flags | DNSConstants.FLAGS_TC); newOut.setId(id); this._jmDNSImpl.send(newOut); newOut = new DNSOutgoing(flags, multicast, maxUDPPayload); newOut.addQuestion(rec); } return newOut; }
@Override protected DNSOutgoing buildOutgoingForDNS(DNSOutgoing out) throws IOException { DNSOutgoing newOut = out; newOut.addQuestion(DNSQuestion.newQuestion(this.getDns().getLocalHost().getName(), DNSRecordType.TYPE_ANY, DNSRecordClass.CLASS_IN, DNSRecordClass.NOT_UNIQUE)); for (DNSRecord answer : this.getDns().getLocalHost().answers(DNSRecordClass.CLASS_ANY, DNSRecordClass.NOT_UNIQUE, this.getTTL())) { newOut = this.addAuthoritativeAnswer(newOut, answer); } return newOut; }
@Override protected DNSOutgoing buildOutgoingForDNS(DNSOutgoing out) throws IOException { DNSOutgoing newOut = out; newOut.addQuestion(DNSQuestion.newQuestion(this.getDns().getLocalHost().getName(), DNSRecordType.TYPE_ANY, DNSRecordClass.CLASS_IN, DNSRecordClass.NOT_UNIQUE)); for (DNSRecord answer : this.getDns().getLocalHost().answers(DNSRecordClass.NOT_UNIQUE, this.getTTL())) { newOut = this.addAuthoritativeAnswer(newOut, answer); } return newOut; }
@Override protected DNSOutgoing buildOutgoingForDNS(DNSOutgoing out) throws IOException { DNSOutgoing newOut = out; newOut.addQuestion(DNSQuestion.newQuestion(this.getDns().getLocalHost().getName(), DNSRecordType.TYPE_ANY, DNSRecordClass.CLASS_IN, DNSRecordClass.NOT_UNIQUE)); for (DNSRecord answer : this.getDns().getLocalHost().answers(DNSRecordClass.NOT_UNIQUE, this.getTTL())) { newOut = this.addAuthoritativeAnswer(newOut, answer); } return newOut; }
@Override protected DNSOutgoing buildOutgoingForDNS(DNSOutgoing out) throws IOException { DNSOutgoing newOut = out; newOut.addQuestion(DNSQuestion.newQuestion(this.getDns().getLocalHost().getName(), DNSRecordType.TYPE_ANY, DNSRecordClass.CLASS_IN, DNSRecordClass.NOT_UNIQUE)); for (DNSRecord answer : this.getDns().getLocalHost().answers(DNSRecordClass.NOT_UNIQUE, this.getTTL())) { newOut = this.addAuthoritativeAnswer(newOut, answer); } return newOut; }