Class SerializationTestKit

  • public class SerializationTestKit
    extends java.lang.Object
    Utilities to test serialization.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      <M> M verifySerialization​(M obj, boolean assertEquality)
      Verify serialization roundtrip.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SerializationTestKit

        public SerializationTestKit​(ActorSystem<?> system)
    • Method Detail

      • verifySerialization

        public <M> M verifySerialization​(M obj,
                                         boolean assertEquality)
        Verify serialization roundtrip. Throws exception from serializer if obj can't be serialized and deserialized.

        obj - the object to verify
        assertEquality - if true the deserialized object is verified to be equal to obj, and if not an AssertionError is thrown
        the deserialized object