Class SecurityManagerDao


public class SecurityManagerDao extends AbstractDao
Provides a DAO for the SecurityManager entity.
Since:
3.5.0
See Also:
  • Constructor Details

    • SecurityManagerDao

      public SecurityManagerDao()
  • Method Details

    • clearThreadLocalCache

      @Deprecated public static void clearThreadLocalCache()
      Deprecated.
      Clear the thread local security manager cache.
      Since:
      4.3.2
    • getSecurityManagerForPK

      public SecurityManager getSecurityManagerForPK(Object id)
      Return the Security Manager instance for the given id.
      Parameters:
      id - the security manager identifier
      Returns:
      the Security Manager instance for the given id
    • getSecurityManagerForPortal

      public SecurityManager getSecurityManagerForPortal(Portal portal) throws ApplicationException
      Return the Security Manager for the given portal, or the default Security Manager if non associated.
      Parameters:
      portal - the request portal
      Returns:
      the Security Manager for the given portal, or the default Security Manager if non associated
      Throws:
      ApplicationException - if the security manager could not be resolved (implying that there is no global default security manager defined)
    • getSecurityManagerList

      public List<SecurityManager> getSecurityManagerList()
      Return the list of Security Managers.
      Returns:
      the list of Security Managers
    • getSecurityManagerList

      public List<SecurityManager> getSecurityManagerList(String keyword, boolean activeOnly)
      Return the list of Security Managers for the given keyword and active status
      Parameters:
      keyword - the search keyword
      activeOnly - specify whether to only show active security manager
      Returns:
      the list of Security Managers
    • getSecurityManagerForName

      public SecurityManager getSecurityManagerForName(String name)
      Gets the security manager for name.
      Parameters:
      name - the name
      Returns:
      the security manager for name
    • getDefaultSecurityManager

      public SecurityManager getDefaultSecurityManager()
      Return the default active Security Manager.
      Returns:
      the default active Security Manager, or null if none is defined (this may be an error case but this needs to be checked by the caller - this method is used in circumstances where there might legitimately not be a security manager)