Udostępnij za pośrednictwem


IWorkspaceSettingsManager Interface

Definition

Per workspace object that is responsible for facilitating the reading and writing the workspace settings as well as corresponding notifications. Retrieved by "Workspace.SettingsManager".

public interface class IWorkspaceSettingsManager
public interface class IWorkspaceSettingsManager
__interface IWorkspaceSettingsManager
public interface IWorkspaceSettingsManager
type IWorkspaceSettingsManager = interface
Public Interface IWorkspaceSettingsManager

Properties

OnWorkspaceSettingsChanged

Event fire when a setting source (a file or in memory provider) changes. Listeners would need to reacquire (via GetAggregatedSettingsAsync) a new settings collection if they need to reflect the settings changes. The SettingsChangedEventArgs parameter can be used to narrow down the changes to a particular settings type and scopePath.

Methods

GetAggregatedSettings(String, String)

the settings reader (note that when reading the settings hierarchy is already applied, the consumer should not differentiate between where property is defined on use). The object returned by this property is immutable. when changes happen a new object will be create (and OnWorkspaceSettingsChanged fired).

will apply build in inheritance override rules(aka PerUser > PerWorkspace > PerMachine) and return the winning value for a named property, array or child settings

GetPersistanceAsync(Boolean)

Access the settings writer. All changes made are in memory until the writer is released. note we will not lock any of the settings files until commit. Also we are not going to lock the writer within the process. the individual actions (like individual property writes) will be protected. We would ensure a machine-wise locking via named event, which will protect against multiple VS instance writing at the same time, yet it would be possible if via other editor (notepad) or when settings file is shared on network, to have a conflicting writes. in this rare case commit may still fail.

GetSettings(String)

"Parse" a single settings file.

Applies to