Package org.eclipse.ui.internal
Class WindowsDefenderConfigurator
java.lang.Object
org.eclipse.ui.internal.WindowsDefenderConfigurator
- All Implemented Interfaces:
EventHandler
A start-up event handler that, if running on Windows, suggests the user to
exclude the current installation directory from being scanned by the Windows
Defender, if it is active on the computer.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final booleanprotected IPreferencesService -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringbindProductName(String message) static StringcreateAddExclusionsPowershellCommand(String extraSeparator) static IEclipsePreferencesgetPreference(IScopeContext instance) voidhandleEvent(Event event) static BooleanOpens the dialog to run the exclusion, regardless of any preference.protected booleanstatic voidsavePreference(IScopeContext scope, String key, String value)
-
Field Details
-
PREFERENCE_STARTUP_CHECK_SKIP
- See Also:
-
PREFERENCE_STARTUP_CHECK_SKIP_DEFAULT
public static final boolean PREFERENCE_STARTUP_CHECK_SKIP_DEFAULT- See Also:
-
preferences
-
-
Constructor Details
-
WindowsDefenderConfigurator
public WindowsDefenderConfigurator()
-
-
Method Details
-
handleEvent
- Specified by:
handleEventin interfaceEventHandler
-
runStartupCheck
protected boolean runStartupCheck() -
runCheckEnforced
Opens the dialog to run the exclusion, regardless of any preference.- Returns:
trueif this installation is now excluded,falseif Windows Defender is inactive and null if the process was aborted.- Throws:
CoreException
-
bindProductName
-
getPreference
-
savePreference
public static void savePreference(IScopeContext scope, String key, String value) throws CoreException - Throws:
CoreException
-
createAddExclusionsPowershellCommand
-