public class DSpaceAuthorityIndexer extends Object implements AuthorityIndexerInterface, org.springframework.beans.factory.InitializingBean
The DSpaceAuthorityIndexer will return a list of all authority values for a given item. It will return an authority value for all metadata fields defined in dspace.conf with 'authority.author.indexer.field'.
You have to call getAuthorityValues for every Item you want to index. But you can supply an optional cache, to save the mapping from the metadata value to the new authority values for metadata fields without an authority key.
| Modifier and Type | Field and Description |
|---|---|
protected AuthorityValueService |
authorityValueService |
protected ConfigurationService |
configurationService |
protected ItemService |
itemService |
protected List<String> |
metadataFields
The list of metadata fields which are to be indexed *
|
| Constructor and Description |
|---|
DSpaceAuthorityIndexer() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
List<AuthorityValue> |
getAuthorityValues(Context context,
Item item) |
List<AuthorityValue> |
getAuthorityValues(Context context,
Item item,
Map<String,AuthorityValue> cache) |
boolean |
isConfiguredProperly() |
protected List<String> metadataFields
@Autowired(required=true) protected AuthorityValueService authorityValueService
@Autowired(required=true) protected ItemService itemService
@Autowired(required=true) protected ConfigurationService configurationService
public void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanExceptionpublic List<AuthorityValue> getAuthorityValues(Context context, Item item) throws SQLException, AuthorizeException
getAuthorityValues in interface AuthorityIndexerInterfaceSQLExceptionAuthorizeExceptionpublic List<AuthorityValue> getAuthorityValues(Context context, Item item, Map<String,AuthorityValue> cache) throws SQLException, AuthorizeException
getAuthorityValues in interface AuthorityIndexerInterfaceSQLExceptionAuthorizeExceptionpublic boolean isConfiguredProperly()
isConfiguredProperly in interface AuthorityIndexerInterfaceCopyright © 2022 LYRASIS. All rights reserved.