@Test public void testToString() { assertToString(Tags.builder(), "{}"); assertToString(Tags.builder().addTag("foo").addTag("bar"), "{bar=[], foo=[]}"); assertToString(Tags.builder().addTag("foo", "value"), "{foo=[value]}"); assertToString(Tags.builder().addTag("foo", ""), "{foo=[]}"); assertToString( Tags.builder() .addTag("foo", "bar") .addTag("foo", true) .addTag("foo", 12.3) .addTag("foo", 42), "{foo=[true, bar, 42, 12.3]}"); }
@Override public String toString() { if (toString == null) { toString = map.toString(); } return toString; }
Tags { @Override public String toString() { if (toString == null) { toString = map.toString(); } return toString; } }
Tags { @Override public String toString() { if (toString == null) { toString = map.toString(); } return toString; } private  Tags(SortedMap<String, SortedSet<Object>> map); }
Tags { @Override public String toString() { if (toString == null) { toString = map.toString(); } return toString; } private  Tags(SortedMap<String, SortedSet<Object>> map); static Builder builder(); static Tags empty(); static Tags of(String name, String value); static Tags of(String name, boolean value); static Tags of(String name, long value); static Tags of(String name, double value); SortedMap<String, SortedSet<Object>> asMap(); boolean isEmpty(); Tags merge(Tags other); @Override boolean equals(@NullableDecl Object obj); @Override int hashCode(); @Override String toString(); }
Tags { @Override public String toString() { if (toString == null) { toString = map.toString(); } return toString; } private  Tags(SortedMap<String, SortedSet<Object>> map); static Builder builder(); static Tags empty(); static Tags of(String name, String value); static Tags of(String name, boolean value); static Tags of(String name, long value); static Tags of(String name, double value); SortedMap<String, SortedSet<Object>> asMap(); boolean isEmpty(); Tags merge(Tags other); @Override boolean equals(@NullableDecl Object obj); @Override int hashCode(); @Override String toString();  }