Class JavaSerializationHints

java.lang.Object
org.springframework.aot.hint.JavaSerializationHints

public class JavaSerializationHints extends Object
Gather the need for Java serialization at runtime.
Since:
6.0
Author:
Stephane Nicoll
See Also:
  • Constructor Details

    • JavaSerializationHints

      public JavaSerializationHints()
  • Method Details

    • types

      public Stream<TypeReference> types()
      Return the types that need to be serialized using Java serialization at runtime.
      Returns:
      a stream of Serializable types
    • registerType

      public JavaSerializationHints registerType(TypeReference type)
      Register that the type defined by the specified TypeReference need to be serialized using java serialization.
      Parameters:
      type - the type to register
      Returns:
      this, to facilitate method chaining
    • registerType

      public JavaSerializationHints registerType(Class<? extends Serializable> type)
      Register that the specified type need to be serialized using java serialization.
      Parameters:
      type - the type to register
      Returns:
      this, to facilitate method chaining