|
Krita Source Code Documentation
|
#include <KisForest.h>
Public Types | |
| using | child_iterator = ChildIterator<T, false> |
| using | composition_iterator = CompositionIterator<T, false> |
| using | const_child_iterator = ChildIterator<T, true> |
| using | const_composition_iterator = CompositionIterator<T, true> |
| using | const_depth_first_tail_iterator = DepthFirstIterator<T, Leave, true> |
| using | const_hierarchy_iterator = HierarchyIterator<T, true> |
| using | const_iterator = DepthFirstIterator<T, Enter, true> |
| using | depth_first_tail_iterator = DepthFirstIterator<T, Leave, false> |
| using | hierarchy_iterator = HierarchyIterator<T, false> |
| using | iterator = DepthFirstIterator<T, Enter, false> |
| using | value_type = T |
Private Member Functions | |
| void | cloneChildren (const_child_iterator oldParent, child_iterator parent) |
| void | linkAfter (Node< T > *node, Node< T > *afterMe) |
| void | linkBefore (Node< T > *node, Node< T > *beforeMe) |
| void | linkNode (child_iterator pos, Node< T > *node) |
| void | unlinkNode (Node< T > *node) |
Static Private Member Functions | |
| template<class ForestType , class IteratorType = DepthFirstIterator<typename ForestType::value_type, Enter, std::is_const_v<ForestType>>> | |
| static IteratorType | beginImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = ChildIterator<typename ForestType::value_type, std::is_const_v<ForestType>>> | |
| static IteratorType | childBeginImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = ChildIterator<typename ForestType::value_type, std::is_const_v<ForestType>>> | |
| static IteratorType | childEndImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = CompositionIterator<typename ForestType::value_type, std::is_const_v<ForestType>>> | |
| static IteratorType | compositionBeginImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = CompositionIterator<typename ForestType::value_type, std::is_const_v<ForestType>>> | |
| static IteratorType | compositionEndImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = DepthFirstIterator<typename ForestType::value_type, Enter, std::is_const_v<ForestType>>> | |
| static IteratorType | endImpl (ForestType &forest) |
| template<class ForestType , class IteratorType = ChildIterator<typename ForestType::value_type, std::is_const_v<ForestType>>> | |
| static IteratorType | parentEndImpl (ForestType &forest) |
Private Attributes | |
| RootNode< T > | m_root |
Forest implements a container for composing tree-like structures from arbitrary objects.
All add/remove operations are implemented via child_iterator. You can convert any iterator type into a child iterator via siblingCurrent() function.
Definition at line 776 of file KisForest.h.
| using KisForestDetail::Forest< T >::child_iterator = ChildIterator<T, false> |
Definition at line 805 of file KisForest.h.
| using KisForestDetail::Forest< T >::composition_iterator = CompositionIterator<T, false> |
Definition at line 808 of file KisForest.h.
| using KisForestDetail::Forest< T >::const_child_iterator = ChildIterator<T, true> |
Definition at line 806 of file KisForest.h.
| using KisForestDetail::Forest< T >::const_composition_iterator = CompositionIterator<T, true> |
Definition at line 809 of file KisForest.h.
| using KisForestDetail::Forest< T >::const_depth_first_tail_iterator = DepthFirstIterator<T, Leave, true> |
Definition at line 818 of file KisForest.h.
| using KisForestDetail::Forest< T >::const_hierarchy_iterator = HierarchyIterator<T, true> |
Definition at line 812 of file KisForest.h.
| using KisForestDetail::Forest< T >::const_iterator = DepthFirstIterator<T, Enter, true> |
Definition at line 815 of file KisForest.h.
| using KisForestDetail::Forest< T >::depth_first_tail_iterator = DepthFirstIterator<T, Leave, false> |
Definition at line 817 of file KisForest.h.
| using KisForestDetail::Forest< T >::hierarchy_iterator = HierarchyIterator<T, false> |
Definition at line 811 of file KisForest.h.
| using KisForestDetail::Forest< T >::iterator = DepthFirstIterator<T, Enter, false> |
Definition at line 814 of file KisForest.h.
| using KisForestDetail::Forest< T >::value_type = T |
Definition at line 803 of file KisForest.h.
|
inline |
Definition at line 779 of file KisForest.h.
|
inline |
Definition at line 783 of file KisForest.h.
References KisForestDetail::Forest< T >::childBegin(), KisForestDetail::Forest< T >::childEnd(), and KisForestDetail::Forest< T >::erase().
|
inline |
Definition at line 787 of file KisForest.h.
References KisForestDetail::Forest< T >::childBegin(), KisForestDetail::Forest< T >::childEnd(), KisForestDetail::Forest< T >::cloneChildren(), and KisForestDetail::Forest< T >::insert().
|
inline |
Definition at line 828 of file KisForest.h.
References KisForestDetail::Forest< T >::beginImpl().
|
inline |
Definition at line 836 of file KisForest.h.
References KisForestDetail::Forest< T >::beginImpl().
|
inlinestaticprivate |
Definition at line 1105 of file KisForest.h.
|
inline |
Definition at line 876 of file KisForest.h.
References KisForestDetail::Forest< T >::childBeginImpl().
|
inline |
Definition at line 888 of file KisForest.h.
References KisForestDetail::Forest< T >::childBeginImpl().
|
inlinestaticprivate |
Definition at line 1083 of file KisForest.h.
|
inline |
Definition at line 880 of file KisForest.h.
References KisForestDetail::Forest< T >::childEndImpl().
|
inline |
Definition at line 892 of file KisForest.h.
References KisForestDetail::Forest< T >::childEndImpl().
|
inlinestaticprivate |
Definition at line 1090 of file KisForest.h.
|
inlineprivate |
Definition at line 1070 of file KisForest.h.
References KisForestDetail::childBegin(), KisForestDetail::childEnd(), KisForestDetail::Forest< T >::cloneChildren(), KisForestDetail::Forest< T >::end(), and KisForestDetail::Forest< T >::insert().
|
inline |
Definition at line 912 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionBeginImpl().
|
inline |
Definition at line 920 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionBeginImpl().
|
inlinestaticprivate |
Definition at line 1121 of file KisForest.h.
|
inline |
Definition at line 916 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionEndImpl().
|
inline |
Definition at line 924 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionEndImpl().
|
inlinestaticprivate |
Definition at line 1128 of file KisForest.h.
|
inline |
Definition at line 844 of file KisForest.h.
References KisForestDetail::Forest< T >::beginImpl().
|
inline |
Definition at line 900 of file KisForest.h.
References KisForestDetail::Forest< T >::childBeginImpl().
|
inline |
Definition at line 904 of file KisForest.h.
References KisForestDetail::Forest< T >::childEndImpl().
|
inline |
Definition at line 928 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionBeginImpl().
|
inline |
Definition at line 932 of file KisForest.h.
References KisForestDetail::Forest< T >::compositionEndImpl().
|
inline |
Definition at line 868 of file KisForest.h.
References KisForestDetail::Forest< T >::constBegin(), and KisForestDetail::tailSubtreeBegin().
|
inline |
Definition at line 872 of file KisForest.h.
References KisForestDetail::Forest< T >::constEnd(), and KisForestDetail::tailSubtreeEnd().
|
inline |
Definition at line 848 of file KisForest.h.
References KisForestDetail::Forest< T >::endImpl().
|
inline |
Definition at line 908 of file KisForest.h.
References KisForestDetail::Forest< T >::parentEndImpl().
|
inline |
Definition at line 852 of file KisForest.h.
References KisForestDetail::Forest< T >::begin(), and KisForestDetail::tailSubtreeBegin().
|
inline |
Definition at line 860 of file KisForest.h.
References KisForestDetail::Forest< T >::constBegin(), and KisForestDetail::tailSubtreeBegin().
|
inline |
Definition at line 856 of file KisForest.h.
References KisForestDetail::Forest< T >::end(), and KisForestDetail::tailSubtreeEnd().
|
inline |
Definition at line 864 of file KisForest.h.
References KisForestDetail::Forest< T >::constEnd(), and KisForestDetail::tailSubtreeEnd().
|
inline |
Definition at line 820 of file KisForest.h.
References KisForestDetail::Forest< T >::m_root.
|
inline |
Definition at line 832 of file KisForest.h.
References KisForestDetail::Forest< T >::endImpl().
|
inline |
Definition at line 840 of file KisForest.h.
References KisForestDetail::Forest< T >::endImpl().
|
inlinestaticprivate |
Definition at line 1113 of file KisForest.h.
|
inline |
Removes element at position pos. If pos is 'end', then result is undefined.
pos Definition at line 956 of file KisForest.h.
References KIS_SAFE_ASSERT_RECOVER_RETURN_VALUE, KisForestDetail::BaseIterator< BaseClass, T, Tag, is_const >::node(), KisForestDetail::tailSubtreeBegin(), KisForestDetail::tailSubtreeEnd(), and KisForestDetail::Forest< T >::unlinkNode().
|
inline |
erases all elements from pos to end (excluding end)
end Definition at line 981 of file KisForest.h.
References KisForestDetail::Forest< T >::erase().
|
inline |
Inserts element value into position pos. value becomes the child of the same parent as pos and is placed right before pos.
Definition at line 943 of file KisForest.h.
References KisForestDetail::Forest< T >::linkNode(), KisForestDetail::RootNodeImpl< Base >::parent, and value().
|
inlineprivate |
Definition at line 1020 of file KisForest.h.
References KisForestDetail::BaseNode< Base >::nextSibling, and KisForestDetail::BaseNode< Base >::prevSibling.
|
inlineprivate |
Definition at line 1013 of file KisForest.h.
References KisForestDetail::BaseNode< Base >::nextSibling, and KisForestDetail::BaseNode< Base >::prevSibling.
|
inlineprivate |
Definition at line 1027 of file KisForest.h.
References KisForestDetail::RootNodeImpl< Base >::firstChild, KIS_SAFE_ASSERT_RECOVER_RETURN, KisForestDetail::RootNodeImpl< Base >::lastChild, KisForestDetail::Forest< T >::linkAfter(), KisForestDetail::Forest< T >::linkBefore(), KisForestDetail::ChildIterator< T, is_const >::m_parent, KisForestDetail::Forest< T >::m_root, KisForestDetail::BaseIterator< BaseClass, T, Tag, is_const >::node(), KisForestDetail::RootNodeImpl< Base >::parent, and KisForestDetail::BaseNode< Base >::prevSibling.
|
inline |
move a subtree to new position Moves subtree into a new position pointer by newPos. newPos must not be inside the subtree, otherwise cycling links may appear.
subtree Definition at line 994 of file KisForest.h.
References KisForestDetail::hierarchyBegin(), KisForestDetail::hierarchyEnd(), KIS_SAFE_ASSERT_RECOVER_RETURN_VALUE, KisForestDetail::Forest< T >::linkNode(), KisForestDetail::BaseNode< Base >::nextSibling, KisForestDetail::BaseIterator< BaseClass, T, Tag, is_const >::node(), KisForestDetail::RootNodeImpl< Base >::parent, KisForestDetail::BaseNode< Base >::prevSibling, and KisForestDetail::Forest< T >::unlinkNode().
|
inline |
Definition at line 794 of file KisForest.h.
References KisForestDetail::Forest< T >::childBegin(), KisForestDetail::Forest< T >::childEnd(), KisForestDetail::Forest< T >::cloneChildren(), KisForestDetail::Forest< T >::erase(), and KisForestDetail::Forest< T >::insert().
|
inline |
Definition at line 884 of file KisForest.h.
References KisForestDetail::Forest< T >::parentEndImpl().
|
inline |
Definition at line 896 of file KisForest.h.
References KisForestDetail::Forest< T >::parentEndImpl().
|
inlinestaticprivate |
Definition at line 1097 of file KisForest.h.
|
inline |
Definition at line 824 of file KisForest.h.
References KisForestDetail::Forest< T >::m_root.
|
inlineprivate |
Definition at line 1049 of file KisForest.h.
References KisForestDetail::RootNodeImpl< Base >::firstChild, KIS_SAFE_ASSERT_RECOVER_RETURN, KisForestDetail::RootNodeImpl< Base >::lastChild, KisForestDetail::BaseNode< Base >::nextSibling, KisForestDetail::RootNodeImpl< Base >::parent, and KisForestDetail::BaseNode< Base >::prevSibling.
|
private |
Definition at line 1134 of file KisForest.h.