Package com.helger.phase4.model.pmode
Class PModeReceptionAwareness
java.lang.Object
com.helger.phase4.model.pmode.PModeReceptionAwareness
- All Implemented Interfaces:
Serializable
@NotThreadSafe
@MustImplementEqualsAndHashcode
public class PModeReceptionAwareness
extends Object
implements Serializable
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final booleanstatic final intstatic final booleanstatic final booleanstatic final long -
Constructor Summary
ConstructorsConstructorDescriptionPModeReceptionAwareness(com.helger.commons.state.ETriState eReceptionAwareness, com.helger.commons.state.ETriState eRetry, int nMaxRetries, long nRetryIntervalMS, com.helger.commons.state.ETriState eDuplicateDetection) -
Method Summary
Modifier and TypeMethodDescriptionstatic PModeReceptionAwarenessbooleanfinal intfinal longinthashCode()final booleanfinal booleanfinal booleanfinal booleanfinal booleanisRetry()final booleanfinal com.helger.commons.state.EChangesetDuplicateDetection(boolean bDuplicateDetection) Set duplicate detectionfinal com.helger.commons.state.EChangesetDuplicateDetection(com.helger.commons.state.ETriState eDuplicateDetection) Set duplicate detectionfinal com.helger.commons.state.EChangesetMaxRetries(int nMaxRetries) Set the maximum number of retries.final com.helger.commons.state.EChangesetReceptionAwareness(boolean bReceptionAwareness) Set the reception awarenessfinal com.helger.commons.state.EChangesetReceptionAwareness(com.helger.commons.state.ETriState eReceptionAwareness) Set the reception awarenessfinal com.helger.commons.state.EChangesetRetry(boolean bRetry) Set enable retryfinal com.helger.commons.state.EChangesetRetry(com.helger.commons.state.ETriState eRetry) Set enable retryfinal com.helger.commons.state.EChangesetRetryIntervalMS(long nRetryIntervalMS) Set the milliseconds to wait between retries.toString()
-
Field Details
-
DEFAULT_RECEPTION_AWARENESS
public static final boolean DEFAULT_RECEPTION_AWARENESS- See Also:
-
DEFAULT_RETRY
public static final boolean DEFAULT_RETRY- See Also:
-
DEFAULT_MAX_RETRIES
public static final int DEFAULT_MAX_RETRIES- See Also:
-
DEFAULT_RETRY_INTERVAL_MS
public static final long DEFAULT_RETRY_INTERVAL_MS- See Also:
-
DEFAULT_DUPLICATE_DETECTION
public static final boolean DEFAULT_DUPLICATE_DETECTION- See Also:
-
-
Constructor Details
-
PModeReceptionAwareness
-
-
Method Details
-
isReceptionAwarenessDefined
public final boolean isReceptionAwarenessDefined()- Returns:
trueif reception awareness is defined,falseif it is undefined. If it is undefined, the default value (DEFAULT_RECEPTION_AWARENESS) will be used.
-
isReceptionAwareness
public final boolean isReceptionAwareness()- Returns:
trueif reception awareness is enabled,falseof not.
-
setReceptionAwareness
@Nonnull public final com.helger.commons.state.EChange setReceptionAwareness(boolean bReceptionAwareness) Set the reception awareness- Parameters:
bReceptionAwareness-trueto enable it,falseto disable it.- Returns:
EChange
-
setReceptionAwareness
@Nonnull public final com.helger.commons.state.EChange setReceptionAwareness(@Nonnull com.helger.commons.state.ETriState eReceptionAwareness) Set the reception awareness- Parameters:
eReceptionAwareness- Value to use. May not benull.- Returns:
EChange
-
isRetryDefined
public final boolean isRetryDefined()- Returns:
trueif retry is defined,falseif it is undefined. If it is undefined, the default value (DEFAULT_RETRY) will be used.
-
isRetry
public final boolean isRetry()- Returns:
trueif retry is enabled,falseof not.
-
setRetry
Set enable retry- Parameters:
bRetry-trueto enable it,falseto disable it.- Returns:
EChange
-
setRetry
@Nonnull public final com.helger.commons.state.EChange setRetry(@Nonnull com.helger.commons.state.ETriState eRetry) Set enable retry- Parameters:
eRetry- Value to use. May not benull.- Returns:
EChange
-
getMaxRetries
- Returns:
- The maximum number of retries. Always ≥ 0.
-
setMaxRetries
Set the maximum number of retries. This value does not include the original try.- Parameters:
nMaxRetries- The maximum number of retries to use. Must be ≥ 0.- Returns:
EChange
-
getRetryIntervalMS
- Returns:
- The milliseconds to wait between retries. Must be ≥ 0.
-
setRetryIntervalMS
@Nonnull public final com.helger.commons.state.EChange setRetryIntervalMS(@Nonnegative long nRetryIntervalMS) Set the milliseconds to wait between retries. This should also be used to define the interval between the original try and the first retry.- Parameters:
nRetryIntervalMS- Milliseconds to wait. Must be ≥ 0.- Returns:
EChange
-
isDuplicateDetectionDefined
public final boolean isDuplicateDetectionDefined()- Returns:
trueif duplication detection is defined,falseif it is undefined. If it is undefined, the default value (DEFAULT_DUPLICATE_DETECTION) will be used.
-
isDuplicateDetection
public final boolean isDuplicateDetection()- Returns:
trueif duplicate detection is enabled,falseof not.
-
setDuplicateDetection
@Nonnull public final com.helger.commons.state.EChange setDuplicateDetection(boolean bDuplicateDetection) Set duplicate detection- Parameters:
bDuplicateDetection-trueto enable it,falseto disable it.- Returns:
EChange
-
setDuplicateDetection
@Nonnull public final com.helger.commons.state.EChange setDuplicateDetection(@Nonnull com.helger.commons.state.ETriState eDuplicateDetection) Set duplicate detection- Parameters:
eDuplicateDetection- Value to use. May not benull.- Returns:
EChange
-
equals
-
hashCode
public int hashCode() -
toString
-
createDefault
- Returns:
- A new
PModeReceptionAwarenessusing the default values. - See Also:
-