SettingsFileManager

internal object SettingsFileManager(source)

Utility methods for managing the settings file underlying PersistentSettings itself.

Properties

Link copied to clipboard

The persistent settings instance.

Link copied to clipboard
internal val SETTINGS_FILE: File

Returns the underlying settings file.

Functions

Link copied to clipboard
private fun DialogBuilder.actionDescriptors(vararg descriptors: DialogBuilder.ActionDescriptor): DialogBuilder

Syntactic sugar to add the given descriptors in a DSL-like fashion.

Link copied to clipboard
internal fun backUpTo(target: File)

Copies the SETTINGS_FILE to target.

Link copied to clipboard
private fun DialogBuilder.cancelButton(): DialogBuilder

Syntactic sugar to add a cancel button in a DSL-like fashion.

Link copied to clipboard
internal fun deleteSettings()

Deletes the SETTINGS_FILE and resets PersistentSettings to its default state.

Link copied to clipboard
internal fun restoreFrom(source: File)

Restores settings into PERSISTENCE from the given source file.

Link copied to clipboard
private fun showBackupDialog(project: Project?)

Runs a dialog-based interface around backUpTo.

Link copied to clipboard
fun showRepairDialog(project: Project? = null, callback: () -> Unit = {})

Shows a dialog with repair options for the settings file.

Link copied to clipboard
fun showRepairNotification(project: Project? = null, group: String, title: String, message: String)

Shows a notification through which users can troubleshoot issues with their settings file.

Link copied to clipboard
private fun showResetDialog(project: Project?): Boolean

Runs a dialog-based interface around deleteSettings.