@Test public void transform() { HashMap<String, Serializable> hash = new HashMap<String, Serializable>(); hash.put("key", "value"); HashMapValueRequestTransformer sut = new HashMapValueRequestTransformer("key"); ServiceActionContext currentContext = new ServiceActionContext(hash, null); assertEquals("value", sut.transform(currentContext)); }
@Override public Serializable transform(final ActionContext inActionContext) { return ((HashMap<String, Serializable>) inActionContext.getParams()).get(key); }
HashMapValueRequestTransformer implements RequestTransformer { @Override public Serializable transform(final ActionContext inActionContext) { return ((HashMap<String, Serializable>) inActionContext.getParams()).get(key); } }
HashMapValueRequestTransformer implements RequestTransformer { @Override public Serializable transform(final ActionContext inActionContext) { return ((HashMap<String, Serializable>) inActionContext.getParams()).get(key); } HashMapValueRequestTransformer(final String inKey); }
HashMapValueRequestTransformer implements RequestTransformer { @Override public Serializable transform(final ActionContext inActionContext) { return ((HashMap<String, Serializable>) inActionContext.getParams()).get(key); } HashMapValueRequestTransformer(final String inKey); @Override Serializable transform(final ActionContext inActionContext); }
HashMapValueRequestTransformer implements RequestTransformer { @Override public Serializable transform(final ActionContext inActionContext) { return ((HashMap<String, Serializable>) inActionContext.getParams()).get(key); } HashMapValueRequestTransformer(final String inKey); @Override Serializable transform(final ActionContext inActionContext);  }