com.jaspersoft.jasperserver.api.metadata.common.service.impl
Class RepositoryServiceSecurityChecker

java.lang.Object
  extended by com.jaspersoft.jasperserver.api.metadata.common.service.impl.RepositoryServiceSecurityChecker

public class RepositoryServiceSecurityChecker
extends java.lang.Object

This class adds security/permission checking utilities for RepositoryService


Constructor Summary
RepositoryServiceSecurityChecker()
           
 
Method Summary
 void filterResource(Resource resource, java.util.Map removableResources, java.util.Map editableResources)
          Filters resource.
 void filterResources(java.util.List allResources, java.util.Map removableResources, java.util.Map editableResources)
          Filters allResources.
 RepositoryService getSecurityChecker()
           
 boolean isEditable(Resource resource)
          Checks whether the given resource can be edited
 boolean isRemovable(Resource resource)
          Checks whether the given resource can be deleted
 void setSecurityChecker(RepositoryService securityChecker)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RepositoryServiceSecurityChecker

public RepositoryServiceSecurityChecker()
Method Detail

filterResources

public void filterResources(java.util.List allResources,
                            java.util.Map removableResources,
                            java.util.Map editableResources)
Filters allResources. Populates removableResources with the resources that can be deleted. Populates editableResources with the resources that can be edited.


filterResource

public void filterResource(Resource resource,
                           java.util.Map removableResources,
                           java.util.Map editableResources)
Filters resource. Adds resource to removableResources if it can be deleted. Adds resource to editableResources if it can be edited.


isEditable

public boolean isEditable(Resource resource)
Checks whether the given resource can be edited


isRemovable

public boolean isRemovable(Resource resource)
Checks whether the given resource can be deleted


getSecurityChecker

public RepositoryService getSecurityChecker()

setSecurityChecker

public void setSecurityChecker(RepositoryService securityChecker)


Copyright © 2007. All Rights Reserved.