Geant4
10.00.p02
|
G4TrackList is used by G4ITStepManager to save G4IT tracks only. More...
#include <G4TrackList.hh>
Public Types | |
typedef G4TrackList_iterator | iterator |
Public Member Functions | |
G4TrackList () | |
~G4TrackList () | |
G4Track * | back () |
G4int | size () const |
bool | empty () const |
iterator | insert (iterator, G4Track *) |
iterator | begin () |
iterator | end () |
bool | Holds (const G4Track *) const |
return an iterator that contains an empty node use for boundary checking only More... | |
void | push_front (G4Track *__track) |
void | push_back (G4Track *__track) |
G4Track * | pop_back () |
void | remove (G4Track *) |
iterator | pop (G4Track *) |
iterator | pop (iterator __first, iterator __last) |
iterator | erase (G4Track *) |
iterator | erase (iterator __first, iterator __last) |
Complexity = constant By storing the node inside the object, we avoid searching through all the container. More... | |
void | transferTo (G4TrackList *) |
Complexity = linear in size between __first and __last. More... | |
Protected Member Functions | |
G4TrackListNode * | CreateNode (G4Track *) |
Complexity = constant. More... | |
G4TrackListNode * | Flag (G4Track *) |
G4TrackListNode * | Unflag (G4Track *) |
void | CheckFlag (G4TrackListNode *) |
void | DeleteTrack (G4Track *) |
void | Hook (G4TrackListNode *, G4TrackListNode *) |
void | Unhook (G4TrackListNode *) |
G4TrackListNode * | EraseTrackListNode (G4Track *) |
Private Member Functions | |
G4TrackList (const G4TrackList &other) | |
G4TrackList & | operator= (const G4TrackList &right) |
G4int | operator== (const G4TrackList &right) const |
G4int | operator!= (const G4TrackList &right) const |
Private Attributes | |
G4int | fNbTracks |
G4TrackListNode * | fpStart |
G4TrackListNode * | fpFinish |
G4ReferenceCountedHandle < _ListRef > | fListRef |
G4TrackListNode | fBoundary |
G4TrackList is used by G4ITStepManager to save G4IT tracks only.
Its advantage lies to a fast search of a track in this list.
Definition at line 106 of file G4TrackList.hh.
Definition at line 120 of file G4TrackList.hh.
G4TrackList::G4TrackList | ( | ) |
Definition at line 77 of file G4TrackList.cc.
References G4TrackListNode::fAttachedToList, fBoundary, fListRef, fNbTracks, fpFinish, fpStart, G4TrackListNode::SetNext(), and G4TrackListNode::SetPrevious().
G4TrackList::~G4TrackList | ( | ) |
Definition at line 107 of file G4TrackList.cc.
References DeleteTrack(), fBoundary, fNbTracks, fpStart, G4TrackListNode::GetNext(), and G4TrackListNode::GetTrack().
|
private |
|
inline |
Definition at line 125 of file G4TrackList.hh.
References G4TrackListNode::GetTrack().
|
inline |
Definition at line 271 of file G4TrackList.hh.
References fpStart.
Referenced by push_front().
|
protected |
Definition at line 269 of file G4TrackList.cc.
References FatalErrorInArgument, fListRef, _ListRef::fpTrackList, G4endl, G4Exception(), GetIT(), G4IT::GetName(), G4TrackListNode::GetTrack(), and G4Track::GetTrackID().
Referenced by Unflag().
|
protected |
Complexity = constant.
Definition at line 170 of file G4TrackList.cc.
References Flag().
Referenced by insert().
|
protected |
Definition at line 335 of file G4TrackList.cc.
References G4Step::DeleteSecondaryVector(), G4Step::GetfSecondary(), and G4Track::GetStep().
Referenced by erase(), and ~G4TrackList().
|
inline |
Definition at line 267 of file G4TrackList.hh.
References fNbTracks.
|
inline |
Definition at line 274 of file G4TrackList.hh.
References fBoundary.
Referenced by push_back().
G4TrackList::iterator G4TrackList::erase | ( | G4Track * | __track | ) |
Definition at line 346 of file G4TrackList.cc.
References DeleteTrack(), and EraseTrackListNode().
Referenced by erase(), and remove().
G4TrackList::iterator G4TrackList::erase | ( | iterator | __first, |
iterator | __last | ||
) |
Complexity = constant By storing the node inside the object, we avoid searching through all the container.
Definition at line 377 of file G4TrackList.cc.
References erase(), fBoundary, and fNbTracks.
|
protected |
Definition at line 325 of file G4TrackList.cc.
References GetIT(), G4TrackListNode::GetNext(), G4IT::SetTrackListNode(), Unflag(), and Unhook().
Referenced by erase().
|
protected |
Definition at line 142 of file G4TrackList.cc.
References FatalErrorInArgument, G4TrackListNode::fAttachedToList, G4TrackListNode::fListRef, fListRef, G4Exception(), GetIT(), G4IT::GetName(), G4IT::GetTrackListNode(), and G4IT::SetTrackListNode().
Referenced by CreateNode().
bool G4TrackList::Holds | ( | const G4Track * | track | ) | const |
return an iterator that contains an empty node use for boundary checking only
Definition at line 137 of file G4TrackList.cc.
References fListRef, _ListRef::fpTrackList, and GetIT().
|
protected |
Definition at line 176 of file G4TrackList.cc.
References fBoundary, fNbTracks, fpFinish, fpStart, G4TrackListNode::GetPrevious(), G4TrackListNode::SetNext(), and G4TrackListNode::SetPrevious().
Referenced by insert().
G4TrackList::iterator G4TrackList::insert | ( | G4TrackList::iterator | __position, |
G4Track * | __track | ||
) |
Definition at line 258 of file G4TrackList.cc.
References CreateNode(), G4TrackList_iterator::fpNode, and Hook().
Referenced by push_back(), and push_front().
|
private |
|
private |
Definition at line 99 of file G4TrackList.cc.
|
private |
G4TrackList::iterator G4TrackList::pop | ( | G4Track * | __track | ) |
Definition at line 317 of file G4TrackList.cc.
References G4TrackListNode::GetNext(), Unflag(), and Unhook().
Referenced by pop().
G4TrackList::iterator G4TrackList::pop | ( | iterator | __first, |
iterator | __last | ||
) |
Definition at line 363 of file G4TrackList.cc.
References fBoundary, fNbTracks, and pop().
G4Track * G4TrackList::pop_back | ( | ) |
Definition at line 308 of file G4TrackList.cc.
References fNbTracks, fpFinish, G4TrackListNode::GetTrack(), Unflag(), and Unhook().
|
inline |
Definition at line 284 of file G4TrackList.hh.
References end(), and insert().
|
inline |
Definition at line 279 of file G4TrackList.hh.
References begin(), and insert().
void G4TrackList::remove | ( | G4Track * | __track | ) |
Definition at line 357 of file G4TrackList.cc.
References erase().
|
inline |
Definition at line 131 of file G4TrackList.hh.
References fNbTracks.
void G4TrackList::transferTo | ( | G4TrackList * | __destination | ) |
Complexity = linear in size between __first and __last.
Definition at line 389 of file G4TrackList.cc.
References fBoundary, fListRef, fNbTracks, fpFinish, fpStart, _ListRef::fpTrackList, G4TrackListNode::SetNext(), and G4TrackListNode::SetPrevious().
|
protected |
Definition at line 288 of file G4TrackList.cc.
References CheckFlag(), FatalErrorInArgument, G4TrackListNode::fAttachedToList, G4TrackListNode::fListRef, G4Exception(), GetIT(), G4IT::GetName(), and G4IT::GetTrackListNode().
Referenced by EraseTrackListNode(), pop(), and pop_back().
|
protected |
Definition at line 225 of file G4TrackList.cc.
References fNbTracks, fpFinish, fpStart, G4TrackListNode::GetNext(), G4TrackListNode::GetPrevious(), G4TrackListNode::SetNext(), and G4TrackListNode::SetPrevious().
Referenced by EraseTrackListNode(), pop(), and pop_back().
|
private |
Definition at line 114 of file G4TrackList.hh.
Referenced by end(), erase(), G4TrackList(), Hook(), pop(), transferTo(), and ~G4TrackList().
|
private |
Definition at line 112 of file G4TrackList.hh.
Referenced by CheckFlag(), Flag(), G4TrackList(), Holds(), and transferTo().
|
private |
Definition at line 109 of file G4TrackList.hh.
Referenced by empty(), erase(), G4TrackList(), Hook(), pop(), pop_back(), size(), transferTo(), Unhook(), and ~G4TrackList().
|
private |
Definition at line 111 of file G4TrackList.hh.
Referenced by G4TrackList(), Hook(), pop_back(), transferTo(), and Unhook().
|
private |
Definition at line 110 of file G4TrackList.hh.
Referenced by begin(), G4TrackList(), Hook(), transferTo(), Unhook(), and ~G4TrackList().