Package i5.las2peer.persistency
Class StopMergingException
java.lang.Object
java.lang.Throwable
java.lang.Exception
i5.las2peer.persistency.StopMergingException
- All Implemented Interfaces:
java.io.Serializable
public class StopMergingException
extends java.lang.Exception
This exception should be thrown by a
StorageCollisionHandler
if there should be no
further merging attempt.- See Also:
- Serialized Form
-
Constructor Summary
Constructors Constructor Description StopMergingException()
Default constructorStopMergingException(long collisions)
This constructor sets only the number of collisions and leaves the message tonull
.StopMergingException(java.lang.String message)
This constructor sets only the message for this exception and leaves the cause tonull
.StopMergingException(java.lang.String message, java.lang.Long collisions)
This constructor allows to set message and number of collisions for this exception. -
Method Summary
Modifier and Type Method Description java.lang.Long
getCollisions()
Gets the number of collisions till this point.java.lang.String
toString()
-
Constructor Details
-
StopMergingException
public StopMergingException()Default constructor -
StopMergingException
public StopMergingException(java.lang.String message)This constructor sets only the message for this exception and leaves the cause tonull
.- Parameters:
message
- A message that describes the error.
-
StopMergingException
public StopMergingException(long collisions)This constructor sets only the number of collisions and leaves the message tonull
.- Parameters:
collisions
- The number of collisions that occurred till this point.
-
StopMergingException
public StopMergingException(java.lang.String message, java.lang.Long collisions)This constructor allows to set message and number of collisions for this exception.- Parameters:
message
- A message that describes the error.collisions
- The number of collisions that occurred till this point.
-
-
Method Details
-
getCollisions
public java.lang.Long getCollisions()Gets the number of collisions till this point.- Returns:
- Returns the number of collisions or
null
.
-
toString
public java.lang.String toString()- Overrides:
toString
in classjava.lang.Throwable
-