Package org.duracloud.retrieval.source
Interface RetrievalSource
- All Known Implementing Classes:
DuraStoreRetrievalSource,DuraStoreSpecifiedRetrievalSource,DuraStoreStitchingRetrievalSource
public interface RetrievalSource
-
Method Summary
Modifier and TypeMethodDescriptionProvides the next content item to be processed, cycles through all spaces as necessary.getSourceChecksum(ContentItem contentItem) Provides the checksum of the specified source file based on the file's properties.default ContentStreamgetSourceContent(ContentItem contentItem) Gets the actual content, including the stream and the checksum.getSourceContent(ContentItem contentItem, RetrievalListener listener) Get the actual content using a retrieval listener callback.getSourceProperties(ContentItem contentItem) Retrieves the Duracloud properties for the specified ContentItem.
-
Method Details
-
getNextContentItem
ContentItem getNextContentItem()Provides the next content item to be processed, cycles through all spaces as necessary. Returns null when there are no further content ids to process.- Returns:
- the next content item to be processed
-
getSourceProperties
Retrieves the Duracloud properties for the specified ContentItem.- Parameters:
contentItem- the file whose properties to retrieve- Returns:
- the Map of Duracloud properties
-
getSourceChecksum
Provides the checksum of the specified source file based on the file's properties.- Parameters:
contentItem- the file to consider- Returns:
- MD5 checksum of the given file
-
getSourceContent
Gets the actual content, including the stream and the checksum.- Parameters:
contentItem- the file to retrieve- Returns:
- content stream of the specified file
-
getSourceContent
Get the actual content using a retrieval listener callback. The listener should be called synchronously.- Parameters:
contentItem- the file to retrievelistener- of the specified operation- Returns:
-