MCPcopy Create free account
hub / github.com/DeNA/PacketProxy / rdataFromString

Method rdataFromString

src/main/java/core/org/xbill/DNS/A6Record.java:62–78  ·  view source on GitHub ↗
(Tokenizer st, Name origin)

Source from the content-addressed store, hash-verified

60}
61
62void
63rdataFromString(Tokenizer st, Name origin) throws IOException {
64 prefixBits = st.getUInt8();
65 if (prefixBits > 128) {
66 throw st.exception("prefix bits must be [0..128]");
67 } else if (prefixBits < 128) {
68 String s = st.getString();
69 try {
70 suffix = Address.getByAddress(s, Address.IPv6);
71 }
72 catch (UnknownHostException e) {
73 throw st.exception("invalid IPv6 address: " + s);
74 }
75 }
76 if (prefixBits > 0)
77 prefix = st.getName(origin);
78}
79
80/** Converts rdata to a String */
81String

Callers

nothing calls this directly

Calls 5

getByAddressMethod · 0.95
getUInt8Method · 0.80
exceptionMethod · 0.80
getNameMethod · 0.65
getStringMethod · 0.45

Tested by

no test coverage detected