Interface IKeystoreEntryViewModel
-
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
CertificateViewModel
public interface IKeystoreEntryViewModel extends Serializable
Common interface for view models of key store entries.- Since:
- 8.5.0
- Author:
- XIMA Media GmbH
-
-
Field Summary
Fields Modifier and Type Field Description static intUPDATE_OFFSET_IN_MINUTES
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description @NotNull InstantgetCreatedAt()Gets the instant when this keystore entry was created.default LocalDategetCreatedAtLocalDate()Returns the creation date as aLocalDate.default LocalDateTimegetCreatedAtLocalDateTime()Returns the creation date and time as aLocalDateTime.StringgetIssuerDisplayName()Gets the display name of the issuer of this keystore entry.List<KeyStoreEntryIssueDetailModel>getIssues()Returns the issues with the keystore entry.KeystoreViewModelgetKeystore()Returns the keystore that contains this keystore entry.StringgetSerialNumber()Returns the serial number of the keystore entry if the keystore entry is a certificate.StringgetStateDescription(Locale locale)Returns the description of the state of the keystore entry.EViewStatusgetStatus()Returns the status of this keystore entry.StringgetSubjectDisplayName()Gets the display name of the subject of this keystore entry.List<EKeystoreEntryTrait>getTraits()Returns the traits of the keystore entry.@NotNull EViewKeystoreEntryTypegetType()Gets the type of the keystore entry.default StringgetTypeDisplayName(Locale locale)Returns the localized display name of the type of the keystore entry.@NotNull InstantgetUpdatedAt()Gets the instant when this keystore entry was last updated.default LocalDategetUpdatedAtLocalDate()Returns the last updated date as aLocalDate.default LocalDateTimegetUpdatedAtLocalDateTime()Returns the last updated date and time as aLocalDateTime.List<KeystoreEntryUsageViewModel>getUsages()A list of the usages of the keystore entry sorted by their localized display name.default InstantgetValidFrom()Gets the instant when this keystore entry is valid from.default LocalDategetValidFromLocalDate()Returns the valid from date as aLocalDate.default LocalDateTimegetValidFromLocalDateTime()Returns the valid from date and time as aLocalDateTime.de.xima.cmn.time.DateTimeRangegetValidity()Returns the validity of the keystore entry.default InstantgetValidUntil()Gets the instant when this keystore entry is valid until.default LocalDategetValidUntilLocalDate()Returns the valid until date as aLocalDate.default LocalDateTimegetValidUntilLocalDateTime()Returns the valid until date and time as aLocalDateTime.default booleanhasIssue(EViewKeystoreEntryIssue issue)Returns whether the keystore entry has the given issue or not.booleanisDeletable()Returns whether this keystore entry is deletable or not.booleanisDownloadable()Returns whether this keystore entry is downloadable or not.default booleanisNew()Returns whether the certificate is new or not.default booleanisRecentlyUpdated()Returns whether this keystore entry has been recently updated or not.
-
-
-
Field Detail
-
UPDATE_OFFSET_IN_MINUTES
static final int UPDATE_OFFSET_IN_MINUTES
- See Also:
- Constant Field Values
-
-
Method Detail
-
getCreatedAt
@NotNull @NotNull Instant getCreatedAt()
Gets the instant when this keystore entry was created.- Returns:
- The instant when this keystore entry was created.
-
getCreatedAtLocalDate
default LocalDate getCreatedAtLocalDate()
Returns the creation date as aLocalDate.- Returns:
- The creation date as a
LocalDate.
-
getCreatedAtLocalDateTime
default LocalDateTime getCreatedAtLocalDateTime()
Returns the creation date and time as aLocalDateTime.- Returns:
- The creation date and time as a
LocalDateTime.
-
getIssuerDisplayName
String getIssuerDisplayName()
Gets the display name of the issuer of this keystore entry.- Returns:
- The display name of the issuer of this keystore entry.
-
getIssues
List<KeyStoreEntryIssueDetailModel> getIssues()
Returns the issues with the keystore entry.- Returns:
- The issues with the keystore entry.
-
getKeystore
KeystoreViewModel getKeystore()
Returns the keystore that contains this keystore entry.- Returns:
- The keystore that contains this keystore entry.
-
getSerialNumber
String getSerialNumber()
Returns the serial number of the keystore entry if the keystore entry is a certificate.- Returns:
- The serial number of the keystore entry if the keystore entry is a certificate or
nullotherwise. - See Also:
for the type of the keystore entry.
-
getStateDescription
String getStateDescription(Locale locale)
Returns the description of the state of the keystore entry.- Parameters:
locale- The locale to use for the description.- Returns:
- The description of the state of the keystore entry.
-
getStatus
EViewStatus getStatus()
Returns the status of this keystore entry.- Returns:
- The status of this keystore entry.
-
getSubjectDisplayName
String getSubjectDisplayName()
Gets the display name of the subject of this keystore entry.- Returns:
- The display name of the subject of this keystore entry.
-
getTraits
List<EKeystoreEntryTrait> getTraits()
Returns the traits of the keystore entry.- Returns:
- The traits of the keystore entry.
-
getType
@NotNull @NotNull EViewKeystoreEntryType getType()
Gets the type of the keystore entry.- Returns:
- The type of the keystore entry.
-
getTypeDisplayName
default String getTypeDisplayName(Locale locale)
Returns the localized display name of the type of the keystore entry.- Parameters:
locale- The locale to use for the display name.- Returns:
- The localized display name of the type of the keystore entry.
-
getUpdatedAt
@NotNull @NotNull Instant getUpdatedAt()
Gets the instant when this keystore entry was last updated.- Returns:
- The instant when this keystore entry was last updated.
-
getUpdatedAtLocalDate
default LocalDate getUpdatedAtLocalDate()
Returns the last updated date as aLocalDate.- Returns:
- The last updated date as a
LocalDate.
-
getUpdatedAtLocalDateTime
default LocalDateTime getUpdatedAtLocalDateTime()
Returns the last updated date and time as aLocalDateTime.- Returns:
- The last updated date and time as a
LocalDateTime.
-
getUsages
List<KeystoreEntryUsageViewModel> getUsages()
A list of the usages of the keystore entry sorted by their localized display name.
-
getValidFrom
default Instant getValidFrom()
Gets the instant when this keystore entry is valid from.- Returns:
- The instant when this keystore entry is valid from.
-
getValidFromLocalDate
default LocalDate getValidFromLocalDate()
Returns the valid from date as aLocalDate.- Returns:
- The valid from date as a
LocalDate.
-
getValidFromLocalDateTime
default LocalDateTime getValidFromLocalDateTime()
Returns the valid from date and time as aLocalDateTime.- Returns:
- The valid from date and time as a
LocalDateTime.
-
getValidUntil
default Instant getValidUntil()
Gets the instant when this keystore entry is valid until.- Returns:
- The instant when this keystore entry is valid until.
-
getValidUntilLocalDate
default LocalDate getValidUntilLocalDate()
Returns the valid until date as aLocalDate.- Returns:
- The valid until date as a
LocalDate.
-
getValidUntilLocalDateTime
default LocalDateTime getValidUntilLocalDateTime()
Returns the valid until date and time as aLocalDateTime.- Returns:
- The valid until date and time as a
LocalDateTime.
-
getValidity
de.xima.cmn.time.DateTimeRange getValidity()
Returns the validity of the keystore entry.- Returns:
- The validity of the keystore entry.
-
hasIssue
default boolean hasIssue(EViewKeystoreEntryIssue issue)
Returns whether the keystore entry has the given issue or not.- Parameters:
issue- The issue to check for.- Returns:
- Whether the keystore entry has the given issue or not.
-
isDeletable
boolean isDeletable()
Returns whether this keystore entry is deletable or not.- Returns:
- Whether this keystore entry is deletable or not.
-
isDownloadable
boolean isDownloadable()
Returns whether this keystore entry is downloadable or not.- Returns:
- Whether this keystore entry is downloadable or not.
-
isNew
default boolean isNew()
Returns whether the certificate is new or not. A certificate is considered new if it was created within the last 5 minutes.- Returns:
- Whether the certificate is new or not.
-
isRecentlyUpdated
default boolean isRecentlyUpdated()
Returns whether this keystore entry has been recently updated or not. An entry is considered recently updated if it was updated within the last 5 minutes.- Returns:
- Whether this keystore entry has been recently updated or not.
-
-