SpringSource/spring-security-oauth — pull request #44 by autayeu (2012-08-14 19:35:04+00:00)
Title: SharedConsumerSecret refactored into interface and implementation

SharedConsumerSecret is refactored into interface (SharedConsumerSecret) and implementation (SharedConsumerSecretImpl).

This allows developers who implement OAuth support to avoid extra object allocation needed to create SharedConsumerSecret object. Instead, they can support the SharedConsumerSecret interface in their existing consumer POJOs on the par with... for example ExtraTrustConsumerDetails. This is particularly useful in case of 2-legged scenario when the amount of consumers is significant and thus the proposed patch allows one to save one object allocation per request.

P.S. There are "Base", "Core" prefixes and "Impl" suffix used for similar cases in the project. I chose "Impl" suffix. Alternatively, it is possible to rename the interface (to let say AbstractSharedConsumerSecret) and keep implementation class name intact (SharedConsumerSecret) for backward compatibility.