Package au.org.ala.web.pac4j
Class ConvertingFromAttributesAuthorizationGenerator
java.lang.Object
au.org.ala.web.pac4j.ConvertingFromAttributesAuthorizationGenerator
- All Implemented Interfaces:
org.pac4j.core.authorization.generator.AuthorizationGenerator
public class ConvertingFromAttributesAuthorizationGenerator
extends Object
implements org.pac4j.core.authorization.generator.AuthorizationGenerator
Copy of the pac4j FromAttributesAuthorizationGenerator that applies the transform in convertProvidedRoleName to role
names before adding them to the user profile.
-
Constructor Summary
ConstructorsConstructorDescriptionConvertingFromAttributesAuthorizationGenerator(String[] roleAttributes, String[] permissionAttributes, String rolePrefix, boolean convertRolesToUpperCase) ConvertingFromAttributesAuthorizationGenerator(Collection<String> roleAttributes, Collection<String> permissionAttributes, String rolePrefix, boolean convertRolesToUpperCase) -
Method Summary
Modifier and TypeMethodDescriptionOptional<org.pac4j.core.profile.UserProfile>generate(org.pac4j.core.context.CallContext callContext, org.pac4j.core.profile.UserProfile profile) voidsetPermissionAttributes(String permissionAttributesStr) voidsetRoleAttributes(String roleAttributesStr) voidsetSplitChar(String splitChar)
-
Constructor Details
-
ConvertingFromAttributesAuthorizationGenerator
public ConvertingFromAttributesAuthorizationGenerator() -
ConvertingFromAttributesAuthorizationGenerator
public ConvertingFromAttributesAuthorizationGenerator(Collection<String> roleAttributes, Collection<String> permissionAttributes, String rolePrefix, boolean convertRolesToUpperCase) -
ConvertingFromAttributesAuthorizationGenerator
-
-
Method Details
-
generate
public Optional<org.pac4j.core.profile.UserProfile> generate(org.pac4j.core.context.CallContext callContext, org.pac4j.core.profile.UserProfile profile) - Specified by:
generatein interfaceorg.pac4j.core.authorization.generator.AuthorizationGenerator
-
getSplitChar
-
setSplitChar
-
setRoleAttributes
-
setPermissionAttributes
-