TransformationMetadataCacheKey implements ContentCacheKey { @Override public String getKey() { return PREFIX + "_" + preparationId + "_" + stepId + "_" + sourceType + "_" + userId; } TransformationMetadataCacheKey(final String preparationId, final String stepId,
            final ExportParameters.SourceType sourceType, final String userId); @Override String getKey(); @Override Predicate<String> getMatcher(); @Override String getPrefix(); String getPreparationId(); String getStepId(); ExportParameters.SourceType getSourceType(); String getUserId(); @Override String toString();  }
@Test public void getKey_should_generate_serialized_key() throws Exception { final ContentCacheKey key = new TransformationMetadataCacheKey("prep1", "step1", HEAD, "user1"); final String keyStr = key.getKey(); assertThat(keyStr, is("transformation-metadata_prep1_step1_HEAD_user1")); }