1 package org.springframework.security.oauth.consumer; 2 3 4 import java.util.Map; 5 6 /** 7 * The OAuth 2 security context (for a specific user). 8 * 9 * @author Ryan Heaton 10 */ 11 public interface OAuthSecurityContext { 12 13 /** 14 * Get the access tokens for the current context. 15 * 16 * @return The access tokens for the current context. The key to the map is the {@link ProtectedResourceDetails#getId() id of the protected resource} 17 * for which the access token is valid. 18 */ 19 Map<String, OAuthConsumerToken> getAccessTokens(); 20 21 /** 22 * Any details for this security this context. 23 * 24 * @return Any details for this security context. 25 */ 26 Object getDetails(); 27 28 }