Class SerializationDebugUtil

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      static void assertSerializable(Object root, StringBuilder report) Asserts that the given object graph is fully serializable.
      static void assertSerializable(Object root) Asserts that the given object graph is fully serializable.
      • Methods inherited from class java.lang.Object

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

    • Method Detail

      • assertSerializable

         static void assertSerializable(Object root, StringBuilder report)

        Asserts that the given object graph is fully serializable. If not, throws an AssertionError with a detailed report of non-serializable fields found.

        Note: When running tests in an IDE, enable "sun.io.serialization.extendedDebugInfo" flag for more detailed stack traces on serialization errors.

        Parameters:
        root - the root object to test for serializability
        report - a StringBuilder instance to which the detailed report is appended
      • assertSerializable

         static void assertSerializable(Object root)

        Asserts that the given object graph is fully serializable. If not, throws an AssertionError with a detailed report of non-serializable fields found.

        Note: When running tests in an IDE, enable "sun.io.serialization.extendedDebugInfo" flag for more detailed stack traces on serialization errors.

        Parameters:
        root - the root object to test for serializability