@Test public void testToString() { assertEquals("h – FTP", BookmarkNameProvider.toString(new Host(new TestProtocol(Scheme.ftp), "h"))); final TestProtocol dav = new TestProtocol(Scheme.http) { @Override public String getName() { return "WebDAV (HTTP)"; } }; assertEquals("h – WebDAV (HTTP)", BookmarkNameProvider.toString(new Host(dav, "h"))); assertEquals("h – WebDAV (HTTP)", BookmarkNameProvider.toString(new Host(dav, "h", new Credentials("u", null)))); assertEquals("u@h – WebDAV (HTTP)", BookmarkNameProvider.toString(new Host(dav, "h", new Credentials("u", null)), true)); assertEquals("h – WebDAV (HTTP)", BookmarkNameProvider.toString(new Host(dav, "h", new Credentials(null, null)), true)); assertEquals("h – WebDAV (HTTP)", BookmarkNameProvider.toString(new Host(dav, "h", new Credentials("", null)), true)); }
public static String toString(final Host bookmark) { return toString(bookmark, false); }
BookmarkNameProvider { public static String toString(final Host bookmark) { return toString(bookmark, false); } }
BookmarkNameProvider { public static String toString(final Host bookmark) { return toString(bookmark, false); } private  BookmarkNameProvider(); }
BookmarkNameProvider { public static String toString(final Host bookmark) { return toString(bookmark, false); } private  BookmarkNameProvider(); static String toString(final Host bookmark); static String toString(final Host bookmark, final boolean username); static String toProtocol(final Host bookmark); static String toHostname(final Host bookmark); static String toHostname(final Host bookmark, final boolean username); }
BookmarkNameProvider { public static String toString(final Host bookmark) { return toString(bookmark, false); } private  BookmarkNameProvider(); static String toString(final Host bookmark); static String toString(final Host bookmark, final boolean username); static String toProtocol(final Host bookmark); static String toHostname(final Host bookmark); static String toHostname(final Host bookmark, final boolean username);  }