Package org.dspace.discovery
Class SolrServiceResourceRestrictionPlugin
- java.lang.Object
-
- org.dspace.discovery.SolrServiceResourceRestrictionPlugin
-
- All Implemented Interfaces:
SolrServiceIndexPlugin,SolrServiceSearchPlugin
public class SolrServiceResourceRestrictionPlugin extends Object implements SolrServiceIndexPlugin, SolrServiceSearchPlugin
Restriction plugin that ensures that indexes all the resource policies. When a search is performed extra filter queries are added to retrieve only results to which the user has READ access- Author:
- Kevin Van de Velde (kevin at atmire dot com), Mark Diggory (markd at atmire dot com), Ben Bosman (ben at atmire dot com)
-
-
Field Summary
Fields Modifier and Type Field Description protected AuthorizeServiceauthorizeServiceprotected CollectionServicecollectionServiceprotected CommunityServicecommunityServiceprotected GroupServicegroupServiceprotected ResourcePolicyServiceresourcePolicyService
-
Constructor Summary
Constructors Constructor Description SolrServiceResourceRestrictionPlugin()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadditionalIndex(Context context, IndexableObject idxObj, org.apache.solr.common.SolrInputDocument document)voidadditionalSearchParameters(Context context, DiscoverQuery discoveryQuery, org.apache.solr.client.solrj.SolrQuery solrQuery)Edits the solr query before it is sent to solr by adding additional parameters to it.
-
-
-
Field Detail
-
authorizeService
@Autowired(required=true) protected AuthorizeService authorizeService
-
communityService
@Autowired(required=true) protected CommunityService communityService
-
collectionService
@Autowired(required=true) protected CollectionService collectionService
-
groupService
@Autowired(required=true) protected GroupService groupService
-
resourcePolicyService
@Autowired(required=true) protected ResourcePolicyService resourcePolicyService
-
-
Method Detail
-
additionalIndex
public void additionalIndex(Context context, IndexableObject idxObj, org.apache.solr.common.SolrInputDocument document)
- Specified by:
additionalIndexin interfaceSolrServiceIndexPlugin
-
additionalSearchParameters
public void additionalSearchParameters(Context context, DiscoverQuery discoveryQuery, org.apache.solr.client.solrj.SolrQuery solrQuery)
Description copied from interface:SolrServiceSearchPluginEdits the solr query before it is sent to solr by adding additional parameters to it.- Specified by:
additionalSearchParametersin interfaceSolrServiceSearchPlugin- Parameters:
context- The DSpace Context object.discoveryQuery- The discovery query object on which the solr query is based.solrQuery- The query that will be sent to solr and which may be edited by this plugin.
-
-