Package org.dspace.app.requestitem
Class CombiningRequestItemStrategy
- java.lang.Object
-
- org.dspace.app.requestitem.CombiningRequestItemStrategy
-
- All Implemented Interfaces:
RequestItemAuthorExtractor
public class CombiningRequestItemStrategy extends Object implements RequestItemAuthorExtractor
Assemble a list of recipients from the results of other strategies. The list of strategy classes is injected as the constructor argumentstrategies. If the strategy list is not configured, returns an empty List.- Author:
- Mark H. Wood
-
-
Constructor Summary
Constructors Constructor Description CombiningRequestItemStrategy(List<RequestItemAuthorExtractor> strategies)Initialize a combination of strategies.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<RequestItemAuthor>getRequestItemAuthor(Context context, Item item)Retrieve the author to contact for requesting a copy of the given item.
-
-
-
Constructor Detail
-
CombiningRequestItemStrategy
public CombiningRequestItemStrategy(@NonNull List<RequestItemAuthorExtractor> strategies)Initialize a combination of strategies.- Parameters:
strategies- the author extraction strategies to combine.
-
-
Method Detail
-
getRequestItemAuthor
@NonNull public List<RequestItemAuthor> getRequestItemAuthor(Context context, Item item) throws SQLException
Description copied from interface:RequestItemAuthorExtractorRetrieve the author to contact for requesting a copy of the given item.- Specified by:
getRequestItemAuthorin interfaceRequestItemAuthorExtractor- Parameters:
context- DSpace context objectitem- item to request- Returns:
- Names and email addresses to send the request to.
- Throws:
SQLException- if database error
-
-