@Test public void testGetQueryParams() throws Exception { final String[][] uriTestPairs = { {"sms:+15555555555", "a", null}, {"mms:+15555555555?b=", "a", null}, {"mmsto:+15555555555?a=", "a", ""}, {"sms:+15555555555?a=b", "a", "b"}, {"sms:+15555555555?a=b&c=d", "a", "b"}, {"sms:+15555555555?a=b&c=d", "b", null}, {"sms:+15555555555?a=b&c=d", "c", "d"}, {"sms:+15555555555?a=b&c=d", "d", null} }; for (String[] uriTestPair : uriTestPairs) { final Rfc5724Uri testUri = new Rfc5724Uri(uriTestPair[0]); final String paramResult = testUri.getQueryParams().get(uriTestPair[1]); if (paramResult == null) assertTrue(uriTestPair[2] == null); else assertTrue(paramResult.equals(uriTestPair[2])); } }
public Map<String, String> getQueryParams() { return queryParams; }
Rfc5724Uri { public Map<String, String> getQueryParams() { return queryParams; } }
Rfc5724Uri { public Map<String, String> getQueryParams() { return queryParams; } Rfc5724Uri(String uri); }
Rfc5724Uri { public Map<String, String> getQueryParams() { return queryParams; } Rfc5724Uri(String uri); String getSchema(); String getPath(); Map<String, String> getQueryParams(); }
Rfc5724Uri { public Map<String, String> getQueryParams() { return queryParams; } Rfc5724Uri(String uri); String getSchema(); String getPath(); Map<String, String> getQueryParams();  }