public void RemoveLink(INode node) { if (node.Linked.Contains(this)) { node.Linked.Remove(this); Linked.Remove(node); } }
public virtual void Unlink(SuperGump gump) { if (gump == null) { return; } Linked.Remove(gump); if (gump.Linked.Contains(this)) { gump.Unlink(this); } }
public void MainTest() { using (Domain.OpenSession()) { using (var t = Session.Current.OpenTransaction()) { var l = new Linked(Guid.NewGuid()); var l2 = new Linked2(Guid.NewGuid()) { Entity = l }; l.Remove(); // Rollback } } }