9template <
class ContainerType>
53template <
class ContainerType,
class ElementType>
78template <
class ContainerType,
class ElementType>
107template <
class ContainerType,
class ElementType,
template<
class,
class>
class IteratorType>
136 NextLink->PrevLink = PrevLink;
140 *PrevLink = NextLink;
157 PrevLink =
Before->PrevLink;
158 Before->PrevLink = &NextLink;
162 if (PrevLink !=
NULL)
164 *PrevLink = (ContainerType*)
this;
177 PrevLink = &
After->NextLink;
178 NextLink = *PrevLink;
179 *PrevLink = (ContainerType*)
this;
181 if (NextLink !=
NULL)
183 NextLink->PrevLink = &NextLink;
203 if (PrevLink !=
NULL)
205 *PrevLink = (ContainerType*)
this;
208 if (NextLink !=
NULL)
210 NextLink->PrevLink = &NextLink;
230 Head->PrevLink = &NextLink;
235 Head = (ContainerType*)
this;
246 return PrevLink !=
nullptr;
266 ContainerType* NextLink;
269 ContainerType** PrevLink;
283template <
class ElementType>
347template <
class ElementType>
361template <
class NodeType,
class ElementType>
374 return CurrentNode !=
nullptr;
380 CurrentNode = CurrentNode->GetNextNode();
394 CurrentNode = CurrentNode->GetPrevNode();
409 return CurrentNode->GetValue();
415 return CurrentNode->GetValue();
428 NodeType* CurrentNode;
437template <
class ElementType>
545 if (NewNode ==
nullptr)
551 if ( HeadNode !=
nullptr )
559 HeadNode = TailNode = NewNode;
580 if ( NewNode ==
nullptr )
585 if ( TailNode !=
nullptr )
593 HeadNode = TailNode = NewNode;
616 if ( NewNode ==
nullptr )
669 HeadNode = TailNode =
nullptr;
708 while ( HeadNode !=
nullptr )
715 HeadNode = TailNode =
nullptr;
752 while ( Node !=
nullptr )
778 return ListSize == 0;
805 TDoubleLinkedListNode* HeadNode;
806 TDoubleLinkedListNode* TailNode;
823template <
class ElementType>
class TList
#define NULL
Definition oodle2base.h:134
#define checkSlow(expr)
Definition AssertionMacros.h:332
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
const bool
Definition NetworkReplayStreaming.h:178
TDoubleLinkedListIterator(NodeType *StartingNode)
Definition List.h:366
TDoubleLinkedListIterator & operator++()
Definition List.h:377
ElementType & operator*() const
Definition List.h:412
TDoubleLinkedListIterator operator--(int)
Definition List.h:398
NodeType * GetNode() const
Definition List.h:418
TDoubleLinkedListIterator & operator--()
Definition List.h:391
TDoubleLinkedListIterator operator++(int)
Definition List.h:384
bool operator==(const TDoubleLinkedListIterator &Rhs) const
Definition List.h:424
bool operator!=(const TDoubleLinkedListIterator &Rhs) const
Definition List.h:425
ElementType & operator->() const
Definition List.h:406
TDoubleLinkedListNode * GetPrevNode()
Definition List.h:472
TDoubleLinkedListNode * PrevNode
Definition List.h:485
ElementType & GetValue()
Definition List.h:457
TDoubleLinkedListNode * GetNextNode()
Definition List.h:462
TDoubleLinkedListNode(const ElementType &InValue)
Definition List.h:447
const TDoubleLinkedListNode * GetPrevNode() const
Definition List.h:477
TDoubleLinkedListNode * NextNode
Definition List.h:484
const ElementType & GetValue() const
Definition List.h:452
const TDoubleLinkedListNode * GetNextNode() const
Definition List.h:467
ElementType Value
Definition List.h:483
friend TConstIterator begin(const TDoubleLinkedList &List)
Definition List.h:810
void RemoveNode(const ElementType &InElement)
Definition List.h:642
bool Contains(const ElementType &InElement)
Definition List.h:765
friend TConstIterator end(const TDoubleLinkedList &List)
Definition List.h:812
TDoubleLinkedList(const TDoubleLinkedList &)=delete
TDoubleLinkedList & operator=(TDoubleLinkedList &&Other)
Definition List.h:521
TDoubleLinkedListNode * GetHead() const
Definition List.h:727
TDoubleLinkedListNode * GetTail() const
Definition List.h:738
bool AddTail(TDoubleLinkedListNode *NewNode)
Definition List.h:578
TDoubleLinkedListIterator< TDoubleLinkedListNode, ElementType > TIterator
Definition List.h:491
bool AddTail(const ElementType &InElement)
Definition List.h:573
friend TIterator begin(TDoubleLinkedList &List)
Definition List.h:809
bool InsertNode(const ElementType &InElement, TDoubleLinkedListNode *NodeToInsertBefore=nullptr)
Definition List.h:609
void Empty()
Definition List.h:705
void RemoveNode(TDoubleLinkedListNode *NodeToRemove, bool bDeleteNode=true)
Definition List.h:654
virtual ~TDoubleLinkedList()
Definition List.h:503
bool InsertNode(TDoubleLinkedListNode *NewNode, TDoubleLinkedListNode *NodeToInsertBefore=nullptr)
Definition List.h:614
friend TIterator end(TDoubleLinkedList &List)
Definition List.h:811
bool AddHead(TDoubleLinkedListNode *NewNode)
Definition List.h:543
TDoubleLinkedList & operator=(const TDoubleLinkedList &)=delete
bool AddHead(const ElementType &InElement)
Definition List.h:538
virtual void SetListSize(int32 NewListSize)
Definition List.h:799
TDoubleLinkedListIterator< TDoubleLinkedListNode, const ElementType > TConstIterator
Definition List.h:492
TDoubleLinkedList()
Definition List.h:495
int32 Num() const
Definition List.h:786
TDoubleLinkedListNode * FindNode(const ElementType &InElement)
Definition List.h:749
bool IsEmpty() const
Definition List.h:776
TDoubleLinkedList(TDoubleLinkedList &&Other)
Definition List.h:513
TIntrusiveLinkedListIterator(ElementType *FirstLink)
Definition List.h:84
ElementType & operator->() const
Definition List.h:90
ElementType & operator*() const
Definition List.h:96
TIntrusiveLinkedList()
Definition List.h:354
void LinkHead(ContainerType *&Head)
Definition List.h:226
UE_FORCEINLINE_HINT bool IsLinked()
Definition List.h:244
IteratorType< ContainerType, const ElementType > TConstIterator
Definition List.h:115
UE_FORCEINLINE_HINT ContainerType * GetNextLink() const
Definition List.h:254
void LinkAfter(ContainerType *After)
Definition List.h:173
void LinkBefore(ContainerType *Before)
Definition List.h:153
void LinkReplace(ContainerType *Replace)
Definition List.h:193
TLinkedListBase()
Definition List.h:121
UE_FORCEINLINE_HINT friend TConstIterator end(const ContainerType &List)
Definition List.h:275
UE_FORCEINLINE_HINT friend TConstIterator begin(const ContainerType &List)
Definition List.h:273
UE_FORCEINLINE_HINT ContainerType * Next()
Definition List.h:259
void Unlink()
Definition List.h:132
UE_FORCEINLINE_HINT friend TIterator end(ContainerType &List)
Definition List.h:274
UE_FORCEINLINE_HINT ContainerType ** GetPrevLink() const
Definition List.h:249
UE_FORCEINLINE_HINT friend TIterator begin(ContainerType &List)
Definition List.h:272
IteratorType< ContainerType, ElementType > TIterator
Definition List.h:114
UE_FORCEINLINE_HINT bool operator==(const TLinkedListIteratorBase &Rhs) const
Definition List.h:46
ContainerType * CurrentLink
Definition List.h:50
UE_FORCEINLINE_HINT bool operator!=(const TLinkedListIteratorBase &Rhs) const
Definition List.h:47
TLinkedListIteratorBase & operator++()
Definition List.h:27
void Next()
Definition List.h:21
TLinkedListIteratorBase operator++(int)
Definition List.h:33
TLinkedListIteratorBase(ContainerType *FirstLink)
Definition List.h:13
ElementType & operator->() const
Definition List.h:65
TLinkedListIterator(ContainerType *FirstLink)
Definition List.h:59
ElementType & operator*() const
Definition List.h:71
UE_FORCEINLINE_HINT const ElementType & operator*() const
Definition List.h:320
UE_FORCEINLINE_HINT const ElementType * operator->() const
Definition List.h:312
UE_FORCEINLINE_HINT ElementType & operator*()
Definition List.h:316
UE_FORCEINLINE_HINT ElementType * operator->()
Definition List.h:308
TLinkedList(const ElementType &InElement)
Definition List.h:300
TLinkedList()
Definition List.h:290
TList(const ElementType &InElement, TList< ElementType > *InNext=nullptr)
Definition List.h:832
ElementType Element
Definition List.h:827
TList< ElementType > * Next
Definition List.h:828