class IndexAnalysisSettingsUpgrader {

    /**
     * De-serialize the specified {@code bytes}, and upgrade if necessary from
     * an older version to the current object version which is
     * {@link IndexAnalysisSettings3}.
     * @param bytes a defined instance
     * @param objectVersion a value greater than or equal to 1
     * @return a defined instance
     * @throws ClassNotFoundException if class of a serialized object cannot be
     * found
     * @throws IOException if any of the usual Input/Output related exceptions
     */
    public IndexAnalysisSettings3 upgrade(byte[] bytes, int objectVersion)
            throws ClassNotFoundException, IOException {
        switch (objectVersion) {
            case 1:
                throw new IOException("Too old version " + objectVersion);
            case 2:
                IndexAnalysisSettings old2 = IndexAnalysisSettings.deserialize(bytes);
                return convertFromV2(old2);
            case 3:
                return IndexAnalysisSettings3.deserialize(bytes);
            default:
                throw new IllegalArgumentException("Unknown version " + objectVersion);
        }
    }

    private IndexAnalysisSettings3 convertFromV2(IndexAnalysisSettings old2) {<FILL_FUNCTION_BODY>}
}

        IndexAnalysisSettings3 res = new IndexAnalysisSettings3();
        res.setAnalyzerGuruVersion(old2.getAnalyzerGuruVersion());
        res.setAnalyzersVersions(old2.getAnalyzersVersions());
        res.setProjectName(old2.getProjectName());
        res.setTabSize(old2.getTabSize());
        // Version 2 has no indexedSymlinks, so nothing more to do.
        return res;
    
<no_super_class>