Class GroovyIxAccessController

java.lang.Object
groovy.lang.GroovyObjectSupport
de.uplanet.lucy.server.scripting.groovy.security.permission.GroovyIxAccessController
All Implemented Interfaces:
groovy.lang.GroovyObject

public final class GroovyIxAccessController extends groovy.lang.GroovyObjectSupport
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    final class 
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    check(groovy.lang.Closure<?> p_closure)
    Check permissions using a GroovyIxAccessController.GroovyIxAccessControllerDelegate as the given closure's delegate object.
    void
    Determines whether the access request indicated by the specified permission should be allowed or denied, based on the security policy currently in effect.
    boolean
    has(groovy.lang.Closure<?> p_closure)
    Test permissions using a boolean expression in the given closure.
    boolean
    hasPermission(Permission p_permission)
    Determines whether the access request indicated by the specified permission should be allowed or denied, based on the security policy currently in effect.

    Methods inherited from class groovy.lang.GroovyObjectSupport

    getMetaClass, setMetaClass

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface groovy.lang.GroovyObject

    getProperty, invokeMethod, setProperty
  • Constructor Details

    • GroovyIxAccessController

      public GroovyIxAccessController()
  • Method Details

    • checkPermission

      public void checkPermission(Permission p_permission)
      Determines whether the access request indicated by the specified permission should be allowed or denied, based on the security policy currently in effect. This method quietly returns if the access request is permitted, or throws a suitable AccessControlException otherwise.
      Parameters:
      p_permission - The requested permission.
      Throws:
      AccessControlException - If the specified permission is not permitted, based on the current security policy.
    • hasPermission

      public boolean hasPermission(Permission p_permission)
      Determines whether the access request indicated by the specified permission should be allowed or denied, based on the security policy currently in effect.
      Parameters:
      p_permission - The requested permission.
      Returns:
      true if the permission is granted, or false if the permission is denied.
    • check

      public void check(groovy.lang.Closure<?> p_closure)
      Check permissions using a GroovyIxAccessController.GroovyIxAccessControllerDelegate as the given closure's delegate object.
      Parameters:
      p_closure - A closure that calls the delegate to check permissions.
      Throws:
      AccessControlException - If not all of the checked permissions are being granted.
    • has

      public boolean has(groovy.lang.Closure<?> p_closure)
      Test permissions using a boolean expression in the given closure.

      The closure's delegate object is a GroovyIxAccessController.GroovyIxAccessControllerDelegate.

      Note: Be sure that the boolean expression whithin the closure does not contain errors.

      Parameters:
      p_closure - A closure that calls the delegate to test for permissions.
      Returns:
      The boolean return value of the closure.