StaticCacheValueTranslator implements CacheValueTranslator<String>, CacheKeyTranslator { @Override public String getValueFromMessage(AdaptrisMessage msg) throws CoreException { return msg.resolve(getValue()); } StaticCacheValueTranslator();  StaticCacheValueTranslator(String s); @Override String getValueFromMessage(AdaptrisMessage msg); void setValue(String s); String getValue(); StaticCacheValueTranslator withValue(String s); @Override String getKeyFromMessage(AdaptrisMessage msg);  }
@Test public void testGetValueFromMessage() throws Exception { StaticCacheValueTranslator translator = new StaticCacheValueTranslator().withValue("Hello"); AdaptrisMessage message = createMessage(); assertEquals("Hello", translator.getValueFromMessage(message)); }