Class SerializationWhitelist

  • public final class SerializationWhitelist
    extends Object
    Implements a serialization whitelist
    • Method Detail

      • configure

        public static void configure​(String whitelistFile)
        Configures a serialization whitelist, does nothing if whitelist is null or empty. Supports 'classpath:' prefix for a whitelist in the classpath root.
        whitelistFile - the path to the file containing the whitelisted class names
      • configureDryRun

        public static void configureDryRun​(String dryRunFile)
        Configures a serialization whitelist for a dry run, does nothing if dryRunFile is null or empty. Note that this will append to an existing file.
        dryRunFile - the dry-run results file to write to, appended to if it exists
        IllegalArgumentException - in case of a classpath dry run file
      • isSerializationDryRunActive

        public static boolean isSerializationDryRunActive()
        Returns true if a serialization dry-run is active.
        true if a dry-run is active.
      • writeDryRunWhitelist

        public static void writeDryRunWhitelist()
        Writes the class names collected during a dry-run to file. If dry-run was not active this method has no effect.