DomainNameMapping implements Mapping<String, V> { @Override public String toString() { return StringUtil.simpleClassName(this) + "(default: " + defaultValue + ", map: " + map + ')'; } @Deprecated  DomainNameMapping(V defaultValue); @Deprecated  DomainNameMapping(int initialCapacity, V defaultValue);   DomainNameMapping(Map<String, V> map, V defaultValue); @Deprecated DomainNameMapping<V> add(String hostname, V output); @Override V map(String hostname); @Override String toString();  }
@Test public void testToString() { DomainNameMapping<String> mapping = new DomainMappingBuilder<String>("NotFound") .add("*.netty.io", "Netty") .add("downloads.netty.io", "Netty-Download") .build(); assertEquals( "ImmutableDomainNameMapping(default: NotFound, map: {*.netty.io=Netty, downloads.netty.io=Netty-Download})", mapping.toString()); }