Class SerializationTestKit
java.lang.Object
org.apache.pekko.actor.testkit.typed.javadsl.SerializationTestKit
Utilities to test serialization.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<M> MverifySerialization(M obj, boolean assertEquality) Verify serialization roundtrip.
-
Constructor Details
-
SerializationTestKit
-
-
Method Details
-
verifySerialization
public <M> M verifySerialization(M obj, boolean assertEquality) Verify serialization roundtrip. Throws exception from serializer ifobjcan't be serialized and deserialized.- Parameters:
obj- the object to verifyassertEquality- iftruethe deserialized object is verified to be equal toobj, and if not anAssertionErroris thrown- Returns:
- the deserialized object
-