Package org.dspace.harvest
Class HarvestedCollection
java.lang.Object
org.dspace.harvest.HarvestedCollection
- All Implemented Interfaces:
ReloadableEntity<Integer>
- Author:
- Alexey Maslov
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedProtected constructor, create object using:HarvestedCollectionService.create(Context, Collection) -
Method Summary
Modifier and TypeMethodDescriptionintintgetID()The unique identifier of this entity instance.voidsetHarvestMessage(String message) voidsetHarvestMetadataConfig(String mdConfigId) voidsetHarvestParams(int type, String oaiSource, String oaiSetId, String mdConfigId) A function to set all harvesting-related parameters at oncevoidsetHarvestStartTime(Instant date) voidsetHarvestStatus(int status) Sets the current status of the collection.voidsetHarvestType(int type) voidsetLastHarvested(Instant lastHarvested) voidsetOaiSetId(String oaiSetId) Sets the OAI set to harvest.voidsetOaiSource(String oaiSource) Sets the base URL of the OAI-PMH server.
-
Field Details
-
TYPE_NONE
public static final int TYPE_NONE- See Also:
-
TYPE_DMD
public static final int TYPE_DMD- See Also:
-
TYPE_DMDREF
public static final int TYPE_DMDREF- See Also:
-
TYPE_FULL
public static final int TYPE_FULL- See Also:
-
STATUS_READY
public static final int STATUS_READY- See Also:
-
STATUS_BUSY
public static final int STATUS_BUSY- See Also:
-
STATUS_QUEUED
public static final int STATUS_QUEUED- See Also:
-
STATUS_OAI_ERROR
public static final int STATUS_OAI_ERROR- See Also:
-
STATUS_UNKNOWN_ERROR
public static final int STATUS_UNKNOWN_ERROR- See Also:
-
-
Constructor Details
-
HarvestedCollection
protected HarvestedCollection()Protected constructor, create object using:HarvestedCollectionService.create(Context, Collection)
-
-
Method Details
-
getID
Description copied from interface:ReloadableEntityThe unique identifier of this entity instance.- Specified by:
getIDin interfaceReloadableEntity<Integer>- Returns:
- the value of the primary key for this instance.
-
setHarvestParams
A function to set all harvesting-related parameters at once- Parameters:
type- harvest type (TYPE_NONE, TYPE_DMD, TYPE_DMDREF, TYPE_FULL)oaiSource- base URL of the OAI-PMH serveroaiSetId- OAI set identifiermdConfigId- harvest metadata config ID
-
setHarvestType
public void setHarvestType(int type) -
setHarvestStatus
public void setHarvestStatus(int status) Sets the current status of the collection.- Parameters:
status- a HarvestInstance.STATUS_... constant (STATUS_READY, STATUS_BUSY, STATUS_QUEUED, STATUS_OAI_ERROR, STATUS_UNKNOWN_ERROR)
-
setOaiSource
Sets the base URL of the OAI-PMH server.- Parameters:
oaiSource- base URL of the OAI-PMH server
-
setOaiSetId
Sets the OAI set to harvest.- Parameters:
oaiSetId- OAI set to harvest
-
setHarvestMetadataConfig
-
setLastHarvested
-
setHarvestMessage
-
setHarvestStartTime
-
getCollection
-
getHarvestType
public int getHarvestType() -
getHarvestStatus
public int getHarvestStatus() -
getOaiSource
-
getOaiSetId
-
getHarvestMetadataConfig
-
getHarvestMessage
-
getHarvestDate
-
getHarvestStartTime
-