com.cleverpine.viravaspringhelper.core.ViravaAuthority Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cp-virava-spring-helper Show documentation
Show all versions of cp-virava-spring-helper Show documentation
Library for Spring Framework projects using Virava
package com.cleverpine.viravaspringhelper.core;
import com.cleverpine.viravaspringhelper.dto.ScopeType;
import org.springframework.security.core.GrantedAuthority;
public class ViravaAuthority implements GrantedAuthority {
private final String authority;
ViravaAuthority(BaseResource resource, ScopeType scope) {
this.authority = String.format("%s_%s", resource.resource(), scope.scope()).toUpperCase();
}
@Override
public String getAuthority() {
return authority;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy