Other implementations might only implement a subset of the three services.
Peter Firmstone wrote:
Well there is one caveat, an PolicySpi object is encapsulated, so I
need two more SPI's, for DynamicPolicy and RevokableDynamicPolicy and
then an internal enum singleton pattern to tie together the
implementation to return the same instance, which has to be threadsafe.
So the sequence goes lookup SPI's in this order, depending upon
required functionality, each SPI provides only its subset, however the
same instance must be called:
1. Policy
2. DynamicPolicy
3. RevokableDynamicPolicy
I could change the interface name to:
DynamicPolicy
DynamicPolicyRevokeable
Cheers,
Peter.