using Quadtree.Items;
using System.Collections.Generic;
using UnityEngine;
namespace Quadtree
{
///
/// Main class of the Quadtree structure - it represents the root of the tree.
///
public interface IQuadtreeRoot
where TItem : IItem
where TNode : INode
{
///
/// The tree has been initialized and is ready to be used.
///
bool Initialized { get; }
///
/// Node currently acting as a root of the tree.
///
TNode CurrentRootNode { get; }
///
/// Minimum possible size of any of the nodes.
///
///
/// Must always be a positive number or zero for no size limit.
///
float MinimumPossibleNodeSize { get; }
///
/// Determines whether or not should number of items in nodes be displayed in gizmos.
///
bool DisplayNumberOfItemsInGizmos { get; }
///
/// Inserts item to the tree structure.
///
///
/// Item to be inserted
void Insert(TItem item);
///
/// Expands size of root node.
/// New root node is created and current root node is assigned as its sub-node.
///
void Expand();
///
/// Finds items located within provided boundaries.
///
///
/// Boundaries to look for items within
/// List of items found within provided boundaries
List Find(Bounds bounds);
///
/// Removes provided item from the tree.
///
///
/// Item to be removed from the tree
void Remove(TItem item);
///
/// Clears and resets the whole tree.
///
void Clear();
}
}