unSet method

bool unSet(
  1. dynamic a,
  2. dynamic b,
  3. dynamic key, {
  4. List anyTags = const [],
  5. List allTags = const [],
})
override

Remove the valued link between 2 nodes, but will not remove a and b and the link between them

(Optional) Only if it matches any of anyTags and matches all items in allTags

Implementation

bool unSet(a, b, key, {List anyTags = const [], List allTags = const []}) {
  return _Tuple2(a, b)
      .map((v) => _map_add_or_get(v, _newNode))
      .where((t) => t
          .mutual((f, t) => _check_hasToVal_and_all_any_val_tags(f, t, key,
              anyTags: anyTags, allTags: allTags))
          .toDo(_or))
      // unsetToV will delete the tab
      .some((t) => t.mutual((f, t) => f.unsetToV(t, key)).toDo(_or))
      .defaultVal(false)
      .val!;
}