public static void save(@NotNull Project project){
  if (!ENABLED) {
    return;
  }
  boolean cacheSaved=false;
  try {
    GradleProjectSyncData data=createFrom(project);
    if (data != null) {
      File file=getProjectStateFile(project);
      ensureExists(file.getParentFile());
      data.saveTo(file);
      cacheSaved=true;
    }
  }
 catch (  IOException e) {
    LOG.info(String.format("Error while saving persistent state from project '%1$s'",project.getName()),e);
  }
  if (!cacheSaved) {
    LOG.info("Failed to generate new cache. Deleting the old one.");
    removeFrom(project);
  }
}

public static void save ( @ NotNull Project project ) { if ( ! ENABLED ) { return ; } boolean cacheSaved = false ; try { GradleProjectSyncData data = createFrom ( project ) ; if ( data != null ) { File file = getProjectStateFile ( project ) ; ensureExists ( file . getParentFile ( ) ) ; data . saveTo ( file ) ; cacheSaved = true ; } } catch ( IOException e ) { LOG . info ( String . format ( "Error while saving persistent state from project '%1$s'" , project . getName ( ) ) , e ) ; } if ( ! cacheSaved ) { LOG . info ( "Failed to generate new cache. Deleting the old one." ) ; removeFrom ( project ) ; } }
persists the gradle sync data of this project to disk .
