public void CountElements(Element element)
 {
     element.Accept(this);
     if (element.Link != null) CountElements(element.Link);
     if (element.Next != null) CountElements(element.Next);
 }