Class AdministrativeAgreement
java.lang.Object
no.unit.nva.model.associatedartifacts.file.File
no.unit.nva.model.associatedartifacts.file.AdministrativeAgreement
- All Implemented Interfaces:
no.unit.nva.commons.json.JsonSerializable,AssociatedArtifact
-
Nested Class Summary
Nested classes/interfaces inherited from class no.unit.nva.model.associatedartifacts.file.File
File.Builder -
Field Summary
FieldsFields inherited from class no.unit.nva.model.associatedartifacts.file.File
ADMINISTRATIVE_AGREEMENT_FIELD, EMBARGO_DATE_FIELD, IDENTIFIER_FIELD, LICENSE_FIELD, LICENSE_MAP, logger, MIME_TYPE_FIELD, MISSING_LICENSE, NAME_FIELD, PUBLISHER_AUTHORITY_FIELD, SIZE_FIELD -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanMethods inherited from class no.unit.nva.model.associatedartifacts.file.File
builder, equals, fileDoesNotHaveActiveEmbargo, getEmbargoDate, getIdentifier, getLicense, getMimeType, getName, getSize, hashCode, isAdministrativeAgreement, isPublisherAuthority, toString, toUnpublishableFile, validateMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface no.unit.nva.commons.json.JsonSerializable
toJsonString
-
Field Details
-
TYPE
- See Also:
-
-
Constructor Details
-
AdministrativeAgreement
public AdministrativeAgreement(UUID identifier, String name, String mimeType, Long size, Object license, boolean administrativeAgreement, boolean publisherAuthority, Instant embargoDate) Constructor for no.unit.nva.file.model.File objects. A file object is valid if it has a license or is explicitly marked as an administrative agreement.- Parameters:
identifier- A UUID that identifies the file in storagename- The original name of the filemimeType- The mimetype of the filesize- The size of the filelicense- The license for the file, may be null if and only if the file is an administrative agreementadministrativeAgreement- True if the file is an administrative agreementpublisherAuthority- True if the file owner has publisher authorityembargoDate- The date after which the file may be published
-
-
Method Details
-
isVisibleForNonOwner
public boolean isVisibleForNonOwner()- Specified by:
isVisibleForNonOwnerin classFile
-
toUnpublishedFile
- Overrides:
toUnpublishedFilein classFile
-
toPublishedFile
- Overrides:
toPublishedFilein classFile
-