Class EntryProcessorResult<V>
- java.lang.Object
-
- com.atlassian.confluence.api.service.journal.EntryProcessorResult<V>
-
@PublicApi public class EntryProcessorResult<V> extends Object
Result of entry processing operation.- Since:
- 5.6
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
static <V> EntryProcessorResult<V>
failure(@Nullable V result, long failedEntryId)
Create a result after a processing failure.Long
getFailedEntryId()
Long
getLastSuccessfulId()
V
getResult()
int
hashCode()
static <V> EntryProcessorResult<V>
partial(@Nullable V result, long lastSuccessfulId)
Create a result after having successfully processed some of the entries.static <V> EntryProcessorResult<V>
success(@Nullable V result)
Create result after having successfully processed all entries.String
toString()
-
-
-
Method Detail
-
getResult
public V getResult()
-
getLastSuccessfulId
public Long getLastSuccessfulId()
-
getFailedEntryId
public Long getFailedEntryId()
-
success
public static <V> EntryProcessorResult<V> success(@Nullable V result)
Create result after having successfully processed all entries.- Type Parameters:
V
- result type- Parameters:
result
- result- Returns:
- result
-
partial
public static <V> EntryProcessorResult<V> partial(@Nullable V result, long lastSuccessfulId)
Create a result after having successfully processed some of the entries.This static factory method should be used when entry processor processed only some of the entries.
- Type Parameters:
V
- result type- Parameters:
result
- resultlastSuccessfulId
- id of the last successfully processed JournalEntry- Returns:
- result
-
failure
public static <V> EntryProcessorResult<V> failure(@Nullable V result, long failedEntryId)
Create a result after a processing failure.This static factory method should be used when an entry could not be processed. Processing should stop immediately after the first failure.
- Type Parameters:
V
- result type- Parameters:
result
- resultfailedEntryId
- id of JournalEntry which could not be processed- Returns:
- result
-
-