Package org.gbif.api.model.occurrence
Class Download
java.lang.Object
org.gbif.api.model.occurrence.Download
- All Implemented Interfaces:
Serializable
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Reflects the possibles statuses of a download during its execution. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) Date
getDoi()
Occurrence download Digital Object Identifier.@NotNull String
getKey()
Get the license assigned to this occurrence download.@Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) Date
Number of datasets in the download file.@NotNull DownloadRequest
Request that originated the download.long
getSize()
Size in bytes of the produced file.Source of the download to determine how the download was originated.@NotNull Download.Status
long
Number of occurrence records in the download file.boolean
void
setCreated
(Date created) void
void
setDownloadLink
(String downloadLink) void
setEraseAfter
(Date eraseAfter) void
setErasureNotification
(Date erasureNotification) void
void
setLicense
(License license) void
setModified
(Date modified) void
setNumberDatasets
(Long numberDatasets) void
setNumberOrganizations
(Long numberOrganizations) void
setNumberPublishingCountries
(Long numberPublishingCountries) void
setRequest
(DownloadRequest request) void
setSize
(long size) void
void
setStatus
(Download.Status status) void
setTotalRecords
(long totalRecords)
-
Constructor Details
-
Download
public Download()
-
-
Method Details
-
getCreated
@Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) @Nullable public @Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) Date getCreated()- Returns:
- timestamp when the download was created
-
getDownloadLink
- Returns:
- the downloadLink
-
getKey
- Returns:
- unique key that can be used in the REST service to retrieve its status
-
getModified
@Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) @Nullable public @Null(groups=PrePersist.class) @NotNull(groups=PostPersist.class) Date getModified()- Returns:
- timestamp when the download result was last modified
-
getEraseAfter
- Returns:
- timestamp after which the download file may be erased
-
getErasureNotification
- Returns:
- timestamp when a notification of an impending file erasure was sent
-
getRequest
Request that originated the download. -
getStatus
- Returns:
- the current download status
-
isAvailable
- Returns:
- true if the download is completed and a result is available
-
getSize
Size in bytes of the produced file. -
getTotalRecords
Number of occurrence records in the download file. -
getNumberDatasets
Number of datasets in the download file. -
getSource
Source of the download to determine how the download was originated. -
getDoi
Occurrence download Digital Object Identifier. -
getLicense
Get the license assigned to this occurrence download. -
setCreated
-
setDownloadLink
-
setKey
-
setDoi
-
setLicense
-
setModified
-
setEraseAfter
-
setErasureNotification
-
setRequest
-
setStatus
-
setSize
-
setTotalRecords
-
setNumberDatasets
-
setSource
-
getNumberOrganizations
-
setNumberOrganizations
-
getNumberPublishingCountries
-
setNumberPublishingCountries
-