Class GroovyPolicyBrowser
java.lang.Object
de.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>
de.uplanet.lucy.server.security.scripting.groovy.GroovyPolicyBrowser
- All Implemented Interfaces:
IPolicyBrowser<PolicyEntryInfo>
@Scriptable
public class GroovyPolicyBrowser
extends de.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>
-
Method Summary
Modifier and TypeMethodDescriptionstatic GroovyPolicyBrowsercreateInstance(de.uplanet.jdbc.JdbcConnection p_conn) Create a policy browser instance.intforEachPolicyEntry(groovy.lang.Closure<?> p_closure) Iterate over all policy entries, ordered by object name.getObjectPolicy(String p_strObjectName) Get the policy for the given object.getPermissionsForContainer(String p_strName) Get the the permissions that are effectively assigned to the given container.getPermissionsForSet(String p_strName) Get the the permissions that are effectively assigned to the given set.getPermissionsForUser(String p_strName) Get the the permissions that are effectively assigned to the given user.
-
Method Details
-
createInstance
Create a policy browser instance.- Parameters:
p_conn- The database connection to be used.- Returns:
- The policy browser instance.
-
getObjectPolicy
Description copied from interface:IPolicyBrowserGet the policy for the given object.- Specified by:
getObjectPolicyin interfaceIPolicyBrowser<PolicyEntryInfo>- Overrides:
getObjectPolicyin classde.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>- Parameters:
p_strObjectName- The name of object.- Returns:
- The policy for the given object.
-
getPermissionsForUser
Description copied from interface:IPolicyBrowserGet the the permissions that are effectively assigned to the given user.- Specified by:
getPermissionsForUserin interfaceIPolicyBrowser<PolicyEntryInfo>- Overrides:
getPermissionsForUserin classde.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>- Parameters:
p_strName- The user's unique identifier.- Returns:
- The permissions that are effectively assigned to the given user.
-
getPermissionsForSet
Description copied from interface:IPolicyBrowserGet the the permissions that are effectively assigned to the given set.- Specified by:
getPermissionsForSetin interfaceIPolicyBrowser<PolicyEntryInfo>- Overrides:
getPermissionsForSetin classde.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>- Parameters:
p_strName- The set's unique identifier.- Returns:
- The permissions that are effectively assigned to the given set.
-
getPermissionsForContainer
Description copied from interface:IPolicyBrowserGet the the permissions that are effectively assigned to the given container.- Specified by:
getPermissionsForContainerin interfaceIPolicyBrowser<PolicyEntryInfo>- Overrides:
getPermissionsForContainerin classde.uplanet.lucy.server.security.scripting.AbstractPolicyBrowser<PolicyEntryInfo>- Parameters:
p_strName- The container's unique identifier.- Returns:
- The permissions that are effectively assigned to the given container.
-
forEachPolicyEntry
public int forEachPolicyEntry(groovy.lang.Closure<?> p_closure) Iterate over all policy entries, ordered by object name. and call the given closure for each of them.- Parameters:
p_closure- The closure that receives thePolicyEntryInfoobjects.- Returns:
- The number of policy entries reported.
-