47 first_ = last_ = item;
72 first_ = last_ = item;
91 DLListBase::link *ap = a->prev_;
100 ap->prev_->next_ = a;
110 a->next_->prev_ = ap;
113 a->prev_ = ap->prev_;
116 ap->next_ = a->next_;
130 DLListBase::link *an = a->
next_;
167 <<
"remove from empty list" 175 DLListBase::link *ret = first_;
176 first_ = first_->next_;
192 DLListBase::link *ret = item;
194 if (item == first_ && first_ == last_)
199 else if (item == first_)
201 first_ = first_->
next_;
202 first_->
prev_ = first_;
204 else if (item == last_)
206 last_ = last_->
prev_;
207 last_->
next_ = last_;
231 if (oldLink == first_ && first_ == last_)
236 else if (oldLink == first_)
241 else if (oldLink == last_)
link * remove(link *item)
Remove and return element.
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
The structure for a doubly-linked storage node.
link * removeHead()
Remove and return first entry.
bool swapDown(link *item)
Swap this element with the one below unless it is at the bottom.
link * replace(link *oldLink, link *newLink)
Replace oldLink with newLink and return element.
link * prev_
Pointer to prev entry in list.
void deregister() noexcept
Deregister the node (after removal)
errorManip< error > abort(error &err)
void push_front(link *item)
Add at front of list.
void push_back(link *item)
Add at back of list.
bool swapUp(link *item)
Swap this element with the one above unless it is at the top.
link * next_
Pointer to next entry in list.