mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-25 11:20:47 +01:00
Implement new CDS changes.
This commit is contained in:
@@ -63,6 +63,7 @@ public final class FeatureFlags {
|
||||
private static final String GROUPS_V2_CREATE = "android.groupsv2.create";
|
||||
private static final String GROUPS_V2_CAPACITY = "android.groupsv2.capacity";
|
||||
private static final String GROUPS_V2_INTERNAL_TEST = "android.groupsv2.internalTest";
|
||||
private static final String CDS = "android.cds";
|
||||
|
||||
/**
|
||||
* We will only store remote values for flags in this set. If you want a flag to be controllable
|
||||
@@ -256,6 +257,11 @@ public final class FeatureFlags {
|
||||
return groupsV2() && getBoolean(GROUPS_V2_INTERNAL_TEST, false);
|
||||
}
|
||||
|
||||
/** Whether or not to use the new contact discovery service endpoint. */
|
||||
public static boolean cds() {
|
||||
return getBoolean(CDS, false);
|
||||
}
|
||||
|
||||
/** Only for rendering debug info. */
|
||||
public static synchronized @NonNull Map<String, Object> getMemoryValues() {
|
||||
return new TreeMap<>(REMOTE_VALUES);
|
||||
|
||||
@@ -19,13 +19,9 @@ public final class SetUtil {
|
||||
return difference;
|
||||
}
|
||||
|
||||
public static <E> Set<E> union(Set<E>... sets) {
|
||||
Set<E> result = new LinkedHashSet<>();
|
||||
|
||||
for (Set<E> set : sets) {
|
||||
result.addAll(set);
|
||||
}
|
||||
|
||||
public static <E> Set<E> union(Set<E> a, Set<E> b) {
|
||||
Set<E> result = new LinkedHashSet<>(a);
|
||||
result.addAll(b);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user