mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
FUS: move dictionary service to event log settings service
This commit is contained in:
+9
-1
@@ -9,6 +9,7 @@ import com.intellij.openapi.diagnostic.Logger;
|
||||
import com.intellij.openapi.util.BuildNumber;
|
||||
import com.intellij.util.ArrayUtil;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.Set;
|
||||
@@ -16,6 +17,7 @@ import java.util.Set;
|
||||
public class EventLogExternalSettingsService extends SettingsConnectionService implements EventLogSettingsService {
|
||||
private static final Logger LOG = Logger.getInstance("com.intellij.internal.statistic.eventLog.EventLogExternalSettingsService");
|
||||
private static final String APPROVED_GROUPS_SERVICE = "white-list-service";
|
||||
private static final String DICTIONARY_SERVICE = "dictionary-service";
|
||||
private static final String PERCENT_TRAFFIC = "percent-traffic";
|
||||
|
||||
public static EventLogExternalSettingsService getInstance() {
|
||||
@@ -29,7 +31,7 @@ public class EventLogExternalSettingsService extends SettingsConnectionService i
|
||||
@NotNull
|
||||
@Override
|
||||
public String[] getAttributeNames() {
|
||||
return ArrayUtil.mergeArrays(super.getAttributeNames(), PERCENT_TRAFFIC, APPROVED_GROUPS_SERVICE);
|
||||
return ArrayUtil.mergeArrays(super.getAttributeNames(), PERCENT_TRAFFIC, APPROVED_GROUPS_SERVICE, DICTIONARY_SERVICE);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -46,6 +48,12 @@ public class EventLogExternalSettingsService extends SettingsConnectionService i
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public String getDictionaryServiceUrl() {
|
||||
return getSettingValue(DICTIONARY_SERVICE);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public Set<String> getApprovedGroups() {
|
||||
return getWhitelistedGroups();
|
||||
|
||||
+3
@@ -9,6 +9,9 @@ public interface EventLogSettingsService {
|
||||
@Nullable
|
||||
String getServiceUrl();
|
||||
|
||||
@Nullable
|
||||
String getDictionaryServiceUrl();
|
||||
|
||||
int getPermittedTraffic();
|
||||
|
||||
@NotNull
|
||||
|
||||
Reference in New Issue
Block a user