/// <summary> /// Iterate over all the storage directories, checking if it should be /// formatted. /// </summary> /// <remarks> /// Iterate over all the storage directories, checking if it should be /// formatted. Format the storage if necessary and allowed by the user. /// </remarks> /// <returns>True if formatting is processed</returns> /// <exception cref="System.IO.IOException"/> private bool Format(NNStorage storage, NamespaceInfo nsInfo) { // Check with the user before blowing away data. if (!Storage.ConfirmFormat(storage.DirIterable(null), force, interactive)) { storage.Close(); return(false); } else { // Format the storage (writes VERSION file) storage.Format(nsInfo); return(true); } }