@Test public void URLにパラメータがついない場合はクエリのハテナがアンドにならない() { String url = "http: PankuzuTag tag = new PankuzuTag(); String trimed = tag.trimQueryMarkerIfGetRequestParameterExists(url, "?addtional=query"); assertThat("?addtional=query", is(trimed)); }
String trimQueryMarkerIfGetRequestParameterExists(String encodedUrl, String query) { if (encodedUrl.contains("?")) { return query.replace("?", ViewId.QUERIES_JOIN_WORD); } return query; }
PankuzuTag extends SimpleTagSupport { String trimQueryMarkerIfGetRequestParameterExists(String encodedUrl, String query) { if (encodedUrl.contains("?")) { return query.replace("?", ViewId.QUERIES_JOIN_WORD); } return query; } }
PankuzuTag extends SimpleTagSupport { String trimQueryMarkerIfGetRequestParameterExists(String encodedUrl, String query) { if (encodedUrl.contains("?")) { return query.replace("?", ViewId.QUERIES_JOIN_WORD); } return query; } PankuzuTag(); }
PankuzuTag extends SimpleTagSupport { String trimQueryMarkerIfGetRequestParameterExists(String encodedUrl, String query) { if (encodedUrl.contains("?")) { return query.replace("?", ViewId.QUERIES_JOIN_WORD); } return query; } PankuzuTag(); void setVar(String var); void setVarStatus(String varStatus); String getVar(); String getVarStatus(); String getScope(); void setScope(String scope); @Override void doTag(); }
PankuzuTag extends SimpleTagSupport { String trimQueryMarkerIfGetRequestParameterExists(String encodedUrl, String query) { if (encodedUrl.contains("?")) { return query.replace("?", ViewId.QUERIES_JOIN_WORD); } return query; } PankuzuTag(); void setVar(String var); void setVarStatus(String varStatus); String getVar(); String getVarStatus(); String getScope(); void setScope(String scope); @Override void doTag();  }