@Test public void rfc3986_fragmentEncodingNotRecommended() { assertEquals("-", PercentEncoder.encodeFragment("-")); assertEquals(".", PercentEncoder.encodeFragment(".")); assertEquals("_", PercentEncoder.encodeFragment("_")); assertEquals("~", PercentEncoder.encodeFragment("~")); assertEquals("0", PercentEncoder.encodeFragment("0")); assertEquals("1", PercentEncoder.encodeFragment("1")); assertEquals("2", PercentEncoder.encodeFragment("2")); assertEquals("3", PercentEncoder.encodeFragment("3")); assertEquals("4", PercentEncoder.encodeFragment("4")); assertEquals("5", PercentEncoder.encodeFragment("5")); assertEquals("6", PercentEncoder.encodeFragment("6")); assertEquals("7", PercentEncoder.encodeFragment("7")); assertEquals("8", PercentEncoder.encodeFragment("8")); assertEquals("9", PercentEncoder.encodeFragment("9")); assertEquals("A", PercentEncoder.encodeFragment("A")); assertEquals("B", PercentEncoder.encodeFragment("B")); assertEquals("C", PercentEncoder.encodeFragment("C")); assertEquals("D", PercentEncoder.encodeFragment("D")); assertEquals("E", PercentEncoder.encodeFragment("E")); assertEquals("F", PercentEncoder.encodeFragment("F")); assertEquals("G", PercentEncoder.encodeFragment("G")); assertEquals("H", PercentEncoder.encodeFragment("H")); assertEquals("I", PercentEncoder.encodeFragment("I")); assertEquals("J", PercentEncoder.encodeFragment("J")); assertEquals("K", PercentEncoder.encodeFragment("K")); assertEquals("L", PercentEncoder.encodeFragment("L")); assertEquals("M", PercentEncoder.encodeFragment("M")); assertEquals("N", PercentEncoder.encodeFragment("N")); assertEquals("O", PercentEncoder.encodeFragment("O")); assertEquals("P", PercentEncoder.encodeFragment("P")); assertEquals("Q", PercentEncoder.encodeFragment("Q")); assertEquals("R", PercentEncoder.encodeFragment("R")); assertEquals("S", PercentEncoder.encodeFragment("S")); assertEquals("T", PercentEncoder.encodeFragment("T")); assertEquals("U", PercentEncoder.encodeFragment("U")); assertEquals("V", PercentEncoder.encodeFragment("V")); assertEquals("W", PercentEncoder.encodeFragment("W")); assertEquals("X", PercentEncoder.encodeFragment("X")); assertEquals("Y", PercentEncoder.encodeFragment("Y")); assertEquals("Z", PercentEncoder.encodeFragment("Z")); assertEquals("a", PercentEncoder.encodeFragment("a")); assertEquals("b", PercentEncoder.encodeFragment("b")); assertEquals("c", PercentEncoder.encodeFragment("c")); assertEquals("d", PercentEncoder.encodeFragment("d")); assertEquals("e", PercentEncoder.encodeFragment("e")); assertEquals("f", PercentEncoder.encodeFragment("f")); assertEquals("g", PercentEncoder.encodeFragment("g")); assertEquals("h", PercentEncoder.encodeFragment("h")); assertEquals("i", PercentEncoder.encodeFragment("i")); assertEquals("j", PercentEncoder.encodeFragment("j")); assertEquals("k", PercentEncoder.encodeFragment("k")); assertEquals("l", PercentEncoder.encodeFragment("l")); assertEquals("m", PercentEncoder.encodeFragment("m")); assertEquals("n", PercentEncoder.encodeFragment("n")); assertEquals("o", PercentEncoder.encodeFragment("o")); assertEquals("p", PercentEncoder.encodeFragment("p")); assertEquals("q", PercentEncoder.encodeFragment("q")); assertEquals("r", PercentEncoder.encodeFragment("r")); assertEquals("s", PercentEncoder.encodeFragment("s")); assertEquals("t", PercentEncoder.encodeFragment("t")); assertEquals("u", PercentEncoder.encodeFragment("u")); assertEquals("v", PercentEncoder.encodeFragment("v")); assertEquals("w", PercentEncoder.encodeFragment("w")); assertEquals("x", PercentEncoder.encodeFragment("x")); assertEquals("y", PercentEncoder.encodeFragment("y")); assertEquals("z", PercentEncoder.encodeFragment("z")); }
public static String encodeFragment(String fragment) { return PercentEncoder.encode(fragment, safeFragment, false, false); }
PercentEncoder { public static String encodeFragment(String fragment) { return PercentEncoder.encode(fragment, safeFragment, false, false); } }
PercentEncoder { public static String encodeFragment(String fragment) { return PercentEncoder.encode(fragment, safeFragment, false, false); }  }
PercentEncoder { public static String encodeFragment(String fragment) { return PercentEncoder.encode(fragment, safeFragment, false, false); }  static String encodePathSegment(String segment); static String encodeQueryComponent(String component); static String encodeQueryComponentNoPlusForSpace(String component); static String encodeFragment(String fragment); static String reEncodePath(String path); static String reEncodeQuery(String query); static String reEncodeFragment(String fragment); }
PercentEncoder { public static String encodeFragment(String fragment) { return PercentEncoder.encode(fragment, safeFragment, false, false); }  static String encodePathSegment(String segment); static String encodeQueryComponent(String component); static String encodeQueryComponentNoPlusForSpace(String component); static String encodeFragment(String fragment); static String reEncodePath(String path); static String reEncodeQuery(String query); static String reEncodeFragment(String fragment);  }