void (Sdk sdk, String previousName) { final Sdk[] sdks = mySdkModel.getSdks(); for (Sdk currentSdk : sdks) { if (currentSdk.getSdkType() instanceof IdeaJdk){ final Sandbox sandbox = (Sandbox)currentSdk.getSdkAdditionalData(); final Sdk internalJava = sandbox.getJavaSdk(); if (internalJava != null && Objects.equals(internalJava.getName(), previousName)){ sandbox.setJavaSdk(sdk); } } } updateJdkList(); }