public static @Nullable long[] cloneOrNull(@Nullable long[] array) {
    return (array != null) ? array.clone() : null;
  }
Removes value from given array if present, providing set-like behavior.
android/android_framework/base/src/main/java/github/tornaco/android/thanos/core/util/ArrayUtils.java