@Override
	public TreeEntry<K, V> remove(Object key) {
		final TreeEntryNode<K, V> target = nodes.remove(key);
		if (ObjectUtil.isNull(target)) {
			return null;
		}
		// 若存在父节点：
		// 1.将该目标从父节点的子节点中移除
		// 2.将目标的子节点直接将目标的父节点作为父节点
		if (target.hasParent()) {
			final TreeEntryNode<K, V> parent = target.getDeclaredParent();
			final Map<K, TreeEntry<K, V>> targetChildren = target.getChildren();
			parent.removeDeclaredChild(target.getKey());
			target.clear();
			targetChildren.forEach((k, c) -> parent.addChild((TreeEntryNode<K, V>) c));
		}
		return target;
	}
@Test
	public void removeTest() {
		final ForestMap<String, String> map = new LinkedForestMap<>(false);
		map.linkNodes("a", "b");
		map.linkNodes("b", "c");

		final TreeEntry<String, String> a = map.get("a");
		final TreeEntry<String, String> b = map.get("b");
		final TreeEntry<String, String> c = map.get("c");

		map.remove("b");
		assertNull(map.get("b"));
		assertFalse(b.hasChildren());
		assertFalse(b.hasParent());
		assertEquals(a, c.getDeclaredParent());
		assertEquals(CollUtil.newArrayList(c), new ArrayList<>(a.getDeclaredChildren().values()));
	}