class MavenRepositorySystemUtils {

    private MavenRepositorySystemUtils() {
        // hide constructor
    }

    /**
     * This method is deprecated, nobody should use it.
     *
     * @deprecated This method is here only for legacy uses (like UTs), nothing else should use it.
     */
    @Deprecated
    public static DefaultRepositorySystemSession newSession() {<FILL_FUNCTION_BODY>}
}

        DefaultRepositorySystemSession session = new DefaultRepositorySystemSession(h -> false); // no close handle
        MavenSessionBuilderSupplier builder = new MavenSessionBuilderSupplier();
        session.setDependencyTraverser(builder.getDependencyTraverser());
        session.setDependencyManager(new ClassicDependencyManager()); // Maven 3 behavior
        session.setDependencySelector(builder.getDependencySelector());
        session.setDependencyGraphTransformer(builder.getDependencyGraphTransformer());
        session.setArtifactTypeRegistry(builder.getArtifactTypeRegistry());
        session.setArtifactDescriptorPolicy(builder.getArtifactDescriptorPolicy());
        return session;
    
<no_super_class>