All Downloads are FREE. Search and download functionalities are using the official Maven repository.

br.com.anteros.security.spring.oauth2.AnterosSecurityApprovalStore Maven / Gradle / Ivy

There is a newer version: 2.0.20
Show newest version
package br.com.anteros.security.spring.oauth2;

import java.util.Collection;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.oauth2.provider.approval.Approval;
import org.springframework.security.oauth2.provider.approval.ApprovalStore;
import org.springframework.stereotype.Component;

import br.com.anteros.security.store.SecurityDataStore;

@Component("approvalStore")
public class AnterosSecurityApprovalStore implements ApprovalStore {
	
	@Autowired
	private SecurityDataStore securityDataStore;

	public boolean addApprovals(Collection approvals) {
		securityDataStore.addApprovals(approvals);
		return true;
	}

	public boolean revokeApprovals(Collection approvals) {
		securityDataStore.revokeApprovals(approvals);
		return true;
	}

	public Collection getApprovals(String userId, String clientId) {
		return securityDataStore.getApprovals(userId,clientId);
	}
	



}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy