com.silverpeas.accesscontrol
Class AttachmentAccessController

java.lang.Object
  extended by com.silverpeas.accesscontrol.AbstractAccessController<AttachmentDetail>
      extended by com.silverpeas.accesscontrol.AttachmentAccessController
All Implemented Interfaces:
AccessController<AttachmentDetail>

@Named
public class AttachmentAccessController
extends AbstractAccessController<AttachmentDetail>

Check the access to an attachment for a user.

Author:
ehugonnet

Constructor Summary
AttachmentAccessController()
           
 
Method Summary
protected  NodeAccessController getNodeAccessController()
          Gets a controller of access on the nodes of a publication.
protected  PublicationBm getPublicationBm()
           
 boolean isUserAuthorized(String userId, AttachmentDetail object, AccessControlContext context)
          Checks if the specified user may access the specified object.
 
Methods inherited from class com.silverpeas.accesscontrol.AbstractAccessController
fillUserRoles, getUserRoles, isUserAuthorized
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttachmentAccessController

public AttachmentAccessController()
Method Detail

isUserAuthorized

public boolean isUserAuthorized(String userId,
                                AttachmentDetail object,
                                AccessControlContext context)
Description copied from interface: AccessController
Checks if the specified user may access the specified object.

Parameters:
userId - the unique identifier of the user.
object - the object to be accessed.
context - the context in which the object is accessed.
Returns:
true if access is granted - false otherwise.

getPublicationBm

protected PublicationBm getPublicationBm()
                                  throws Exception
Throws:
Exception

getNodeAccessController

protected NodeAccessController getNodeAccessController()
Gets a controller of access on the nodes of a publication.

Returns:
a NodeAccessController instance.


Copyright © 2016 Silverpeas. All Rights Reserved.