Package eu.europa.esig.dss.tsl.dto
Class AbstractCacheDTO
java.lang.Object
eu.europa.esig.dss.tsl.dto.AbstractCacheDTO
- All Implemented Interfaces:
InfoRecord
,Serializable
- Direct Known Subclasses:
DownloadCacheDTO
,ParsingCacheDTO
,ValidationCacheDTO
The abstract cache DTO
- See Also:
-
Constructor Summary
ConstructorDescriptionEmpty constructorAbstractCacheDTO
(AbstractCacheDTO cacheDTO) Copies the cache DTO -
Method Summary
Modifier and TypeMethodDescriptionGets the state of the cacheGets the first time when the error is occurredGets the last time when the error is occurredGets the exception message for an error stateGets the exception stack trace for an error stateGets the last time when the state of record has been changedGets the last time when the record has been synchronizedGets the record's status nameboolean
Gets if the record is desynchronizedboolean
isError()
Gets if the error is present for the recordboolean
Gets if the refresh is needed for an entryboolean
Gets if a result exist under the recordboolean
Gets if the record is synchronizedboolean
Gets if the record shall be deletedvoid
setCacheState
(CacheStateEnum cacheState) Sets the cache statevoid
setExceptionFirstOccurrenceTime
(Date exceptionFirstOccurrenceTime) Sets the first time of the exception occurrencevoid
setExceptionLastOccurrenceTime
(Date exceptionLastOccurrenceTime) Sets the last time of a the exception occurrencevoid
setExceptionMessage
(String exceptionMessage) Sets the exception messagevoid
setExceptionStackTrace
(String exceptionStackTrace) Sets the exception stack tracevoid
setLastStateTransitionTime
(Date lastStateTransitionTime) Sets the last time of the state changevoid
setLastSuccessSynchronizationTime
(Date lastSuccessSynchronizationTime) Sets the last time of a successful synchronizationvoid
setResultExist
(boolean resultExist) Sets if the cache result exists
-
Constructor Details
-
AbstractCacheDTO
public AbstractCacheDTO()Empty constructor -
AbstractCacheDTO
Copies the cache DTO- Parameters:
cacheDTO
-AbstractCacheDTO
to copy
-
-
Method Details
-
getCacheState
-
setCacheState
Sets the cache state- Parameters:
cacheState
-CacheStateEnum
-
getLastStateTransitionTime
Description copied from interface:InfoRecord
Gets the last time when the state of record has been changed- Specified by:
getLastStateTransitionTime
in interfaceInfoRecord
- Returns:
Date
-
setLastStateTransitionTime
-
getLastSuccessSynchronizationTime
Description copied from interface:InfoRecord
Gets the last time when the record has been synchronized- Specified by:
getLastSuccessSynchronizationTime
in interfaceInfoRecord
- Returns:
Date
-
setLastSuccessSynchronizationTime
-
getExceptionMessage
Description copied from interface:InfoRecord
Gets the exception message for an error state- Specified by:
getExceptionMessage
in interfaceInfoRecord
- Returns:
String
-
setExceptionMessage
-
getExceptionStackTrace
Description copied from interface:InfoRecord
Gets the exception stack trace for an error state- Specified by:
getExceptionStackTrace
in interfaceInfoRecord
- Returns:
String
-
setExceptionStackTrace
-
getExceptionFirstOccurrenceTime
Description copied from interface:InfoRecord
Gets the first time when the error is occurred- Specified by:
getExceptionFirstOccurrenceTime
in interfaceInfoRecord
- Returns:
Date
-
setExceptionFirstOccurrenceTime
-
getExceptionLastOccurrenceTime
Description copied from interface:InfoRecord
Gets the last time when the error is occurred- Specified by:
getExceptionLastOccurrenceTime
in interfaceInfoRecord
- Returns:
Date
-
setExceptionLastOccurrenceTime
-
isResultExist
public boolean isResultExist()Description copied from interface:InfoRecord
Gets if a result exist under the record- Specified by:
isResultExist
in interfaceInfoRecord
- Returns:
- TRUE if the result exists, FALSE otherwise
-
setResultExist
public void setResultExist(boolean resultExist) Sets if the cache result exists- Parameters:
resultExist
- if the cache result exists
-
isRefreshNeeded
public boolean isRefreshNeeded()Description copied from interface:InfoRecord
Gets if the refresh is needed for an entry- Specified by:
isRefreshNeeded
in interfaceInfoRecord
- Returns:
- TRUE if the refresh is needed, FALSE otherwise
-
isDesynchronized
public boolean isDesynchronized()Description copied from interface:InfoRecord
Gets if the record is desynchronized- Specified by:
isDesynchronized
in interfaceInfoRecord
- Returns:
- TRUE if the record is desynchronized, FALSE otherwise
-
isSynchronized
public boolean isSynchronized()Description copied from interface:InfoRecord
Gets if the record is synchronized- Specified by:
isSynchronized
in interfaceInfoRecord
- Returns:
- TRUE if the record is synchronized, FALSE otherwise
-
isError
public boolean isError()Description copied from interface:InfoRecord
Gets if the error is present for the record- Specified by:
isError
in interfaceInfoRecord
- Returns:
- TRUE if the record defines an error, FALSE otherwise
-
isToBeDeleted
public boolean isToBeDeleted()Description copied from interface:InfoRecord
Gets if the record shall be deleted- Specified by:
isToBeDeleted
in interfaceInfoRecord
- Returns:
- TRUE if the record shall be deleted, FALSE otherwise
-
getStatusName
Description copied from interface:InfoRecord
Gets the record's status name- Specified by:
getStatusName
in interfaceInfoRecord
- Returns:
String
-