@Test(expectedExceptions = IllegalArgumentException.class) public void testSetUnsupportedKeyFormat() { this.cache.set("key", ""); }
@Override void set(final String key, final String value) { if (isPolicySetChangedKey(key) || isResourceChangedKey(key) || isSubjectChangedKey(key) || isPolicyEvalResultKey(key)) { this.evalCache.put(key, value); } else { throw new IllegalArgumentException("Unsupported key format."); } }
InMemoryPolicyEvaluationCache extends AbstractPolicyEvaluationCache { @Override void set(final String key, final String value) { if (isPolicySetChangedKey(key) || isResourceChangedKey(key) || isSubjectChangedKey(key) || isPolicyEvalResultKey(key)) { this.evalCache.put(key, value); } else { throw new IllegalArgumentException("Unsupported key format."); } } }
InMemoryPolicyEvaluationCache extends AbstractPolicyEvaluationCache { @Override void set(final String key, final String value) { if (isPolicySetChangedKey(key) || isResourceChangedKey(key) || isSubjectChangedKey(key) || isPolicyEvalResultKey(key)) { this.evalCache.put(key, value); } else { throw new IllegalArgumentException("Unsupported key format."); } }  }
InMemoryPolicyEvaluationCache extends AbstractPolicyEvaluationCache { @Override void set(final String key, final String value) { if (isPolicySetChangedKey(key) || isResourceChangedKey(key) || isSubjectChangedKey(key) || isPolicyEvalResultKey(key)) { this.evalCache.put(key, value); } else { throw new IllegalArgumentException("Unsupported key format."); } }   }
InMemoryPolicyEvaluationCache extends AbstractPolicyEvaluationCache { @Override void set(final String key, final String value) { if (isPolicySetChangedKey(key) || isResourceChangedKey(key) || isSubjectChangedKey(key) || isPolicyEvalResultKey(key)) { this.evalCache.put(key, value); } else { throw new IllegalArgumentException("Unsupported key format."); } }    }