/* Copyright 2007-2013 The NGenerics Team (https://github.com/ngenerics/ngenerics/wiki/Team) This program is licensed under the GNU Lesser General Public License (LGPL). You should have received a copy of the license along with the source code. If not, an online copy of the license can be found at http://www.gnu.org/copyleft/lesser.html. */ using System; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using NGenerics.Patterns.Visitor; namespace NGenerics.DataStructures.Trees { /// /// An interface for Search Trees that mimic a dictionary. /// /// The type of element to hold in the tree. [SuppressMessage("Microsoft.Naming", "CA1710:IdentifiersShouldHaveCorrectSuffix")] public interface ISearchTree : ICollection { /// /// Gets the largest item in the tree. /// /// The largest item in the tree. /// The is empty. T Maximum { get; } /// /// Gets the smallest item in the tree. /// /// The smallest item in the tree. /// The is empty. T Minimum { get; } /// /// Performs a depth first traversal on the search tree. /// /// The visitor to use. /// is a null reference (Nothing in Visual Basic). /// /// /// /// [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures")] void DepthFirstTraversal(OrderedVisitor visitor); /// /// Returns an enumerator that iterates through the collection. /// /// /// A that can be used to iterate through the collection. /// /// /// /// /// [SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures")] [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] IEnumerator GetOrderedEnumerator(); } }