本文整理了Java中org.hswebframework.web.authorization.Authentication.getPermissions()
方法的一些代码示例,展示了Authentication.getPermissions()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Authentication.getPermissions()
方法的具体详情如下:
包路径:org.hswebframework.web.authorization.Authentication
类名称:Authentication
方法名:getPermissions
暂无
代码示例来源:origin: hs-web/hsweb-framework
/**
* 根据权限id获取权限信息,权限不存在则返回null
*
* @param id 权限id
* @return 权限信息
*/
default Optional<Permission> getPermission(String id) {
if (null == id) {
return Optional.empty();
}
return getPermissions().stream()
.filter(permission -> permission.getId().equals(id))
.findAny();
}
代码示例来源:origin: hs-web/hsweb-framework
String[] permissionAndActions = conf.split("[:]", 2);
if (permissionAndActions.length < 2) {
temp = authentication -> !authentication.getPermissions().isEmpty();
} else {
String[] real = permissionAndActions[1].split("[:]");
代码示例来源:origin: hs-web/hsweb-framework
List<Permission> permission = context.getAuthentication().getPermissions()
.stream()
.filter(per -> context.getDefinition().getPermissions().contains(per.getId()))
代码示例来源:origin: hs-web/hsweb-framework
actionsDef);
List<Permission> permissions = authentication.getPermissions().stream()
.filter(permission -> {
代码示例来源:origin: org.hswebframework.web/hsweb-authorization-basic
List<Permission> permission = context.getAuthentication().getPermissions()
.stream()
.filter(per -> context.getDefinition().getPermissions().contains(per.getId()))
代码示例来源:origin: org.hswebframework.web/hsweb-authorization-basic
actionsDef);
List<Permission> permissions = authentication.getPermissions().stream()
.filter(permission -> {
内容来源于网络,如有侵权,请联系作者删除!