MCPcopy Create free account
hub / github.com/antlr/codebuff / toString

Method toString

output/java_guava/1.4.19/HashCode.java:435–443  ·  view source on GitHub ↗

Returns a string containing each byte of #asBytes, in order, as a two-digit unsigned hexadecimal number in lower case. Note that if the output is considered to be a single hexadecimal number, this hash code's bytes are the big-endian representation of that number. This may be surp

()

Source from the content-addressed store, hash-verified

433 */
434
435 @Override
436 public final String toString() {
437 byte[] bytes = getBytesInternal();
438 StringBuilder sb = new StringBuilder(2 * bytes.length);
439 for (byte b : bytes) {
440 sb.append(hexDigits[(b >> 4) & 0xf]).append(hexDigits[b & 0xf]);
441 }
442 return sb.toString();
443 }
444
445 private static final char[] hexDigits = "0123456789abcdef".toCharArray();
446}

Callers

nothing calls this directly

Calls 3

getBytesInternalMethod · 0.95
toStringMethod · 0.65
appendMethod · 0.45

Tested by

no test coverage detected