站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBOSS Portal 2.6 API 英文版文档

PortalPermission - JBOSS Portal 2.6 API 英文版文档


org.jboss.portal.security
Class PortalPermission

java.lang.Object
  extended byjava.security.Permission
      extended byorg.jboss.portal.security.PortalPermission
All Implemented Interfaces:
java.security.Guard, java.io.Serializable
Direct Known Subclasses:
FlatPermission, HierarchyPermission, InstancePermission, PortalObjectPermission, PortletPermission

public abstract class PortalPermission
extends java.security.Permission

Base permission that can act either as a container or as a permission that has an URI.

Version:
$Revision: 5448 $
Author:
Julien Viet
See Also:
Serialized Form

Field Summary
protected  PortalPermissionCollection collection
          .
protected  java.lang.String uri
          .
 
Fields inherited from class java.security.Permission
 
Constructor Summary
PortalPermission(java.lang.String name, PortalPermissionCollection collection)
           
PortalPermission(java.lang.String name, java.lang.String uri)
           
 
Method Summary
abstract  java.lang.String getType()
          Return the portal permission type.
 java.lang.String getURI()
          Return the uri for the permission or null if the permission acts as a container.
abstract  boolean implies(PermissionRepository repository, javax.security.auth.Subject caller, java.lang.String roleName, PortalPermission permission)
          Implement the imply logic when we check the permission against a domain.
 boolean isContainer()
          Return true if the permission is a container.
 java.security.PermissionCollection newPermissionCollection()
          Return an instance of PortalPermissionCollection or null if the permission does not act as a container.
 
Methods inherited from class java.security.Permission
checkGuard, equals, getActions, getName, hashCode, implies, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

uri

protected final java.lang.String uri
.


collection

protected final PortalPermissionCollection collection
.

Constructor Detail

PortalPermission

public PortalPermission(java.lang.String name,
                        PortalPermissionCollection collection)

PortalPermission

public PortalPermission(java.lang.String name,
                        java.lang.String uri)
Method Detail

getURI

public java.lang.String getURI()
Return the uri for the permission or null if the permission acts as a container.


newPermissionCollection

public java.security.PermissionCollection newPermissionCollection()
Return an instance of PortalPermissionCollection or null if the permission does not act as a container.


isContainer

public boolean isContainer()
Return true if the permission is a container.


getType

public abstract java.lang.String getType()
Return the portal permission type.

Returns:
the portal permission type

implies

public abstract boolean implies(PermissionRepository repository,
                                javax.security.auth.Subject caller,
                                java.lang.String roleName,
                                PortalPermission permission)
                         throws PortalSecurityException
Implement the imply logic when we check the permission against a domain.

Parameters:
repository -
caller -
permission -
Returns:
true if the permission is implied
Throws:
PortalSecurityException