SNAP Library 4.0, Developer Reference
2017-07-27 13:18:06
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
|
Fast Queue used by the TBreathFS
(uses memcpy
to move objects TVal
around).
More...
#include <gbase.h>
Public Member Functions | |
TSnapQueue () | |
TSnapQueue (const int &MxVals) | |
Constructor that reserves enough memory for a queue with MxVals elements. More... | |
TSnapQueue (const int &MxVals, const int &MaxFirst) | |
TSnapQueue (const TSnapQueue &Queue) | |
TSnapQueue (TSIn &SIn) | |
Constructor that loads the queue from a (binary) stream SIn. More... | |
void | Save (TSOut &SOut) const |
Saves the queue to a (binary) stream SOut. More... | |
TSnapQueue & | operator= (const TSnapQueue &Queue) |
const TVal & | operator[] (const int &ValN) const |
Returns the value of the ValN element in the queue, but does not remove the element. More... | |
void | Clr (const bool &DoDel=true) |
Deletes all elements from the queue. More... | |
void | Gen (const int &MxVals, const int &MaxFirst=1024) |
bool | Empty () const |
Tests whether the queue is empty (contains no elements). More... | |
int | Len () const |
Returns the number of elements in the queue. More... | |
int | GetFirst () const |
Returns the location of the first element in the queue. More... | |
int | GetLast () const |
Returns the location of the last element in the queue. More... | |
int | Reserved () const |
const TVal & | Top () const |
Returns the value of the first element in the queue, but does not remove the element. More... | |
void | Pop () |
Removes the first element from the queue. More... | |
void | Push (const TVal &Val) |
Adds an element at the end of the queue. More... | |
Private Attributes | |
TInt | MxFirst |
TInt | First |
TInt | Last |
TVec< TVal > | ValV |
Fast Queue used by the TBreathFS
(uses memcpy
to move objects TVal
around).
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineexplicit |
|
inline |
|
inline |
Tests whether the queue is empty (contains no elements).
Definition at line 186 of file gbase.h.
Referenced by TSnap::CascFind(), TSnap::CascFindMP(), and MAPPR::computeAPPR().
|
inline |
|
inline |
|
inline |
|
inline |
Returns the number of elements in the queue.
Definition at line 188 of file gbase.h.
Referenced by TSnapQueue< int >::Push().
|
inline |
|
inline |
|
inline |
Removes the first element from the queue.
Definition at line 198 of file gbase.h.
Referenced by TSnap::CascFind(), TSnap::CascFindMP(), and MAPPR::computeAPPR().
|
inline |
Adds an element at the end of the queue.
Definition at line 201 of file gbase.h.
Referenced by TSnap::CascFind(), TSnap::CascFindMP(), MAPPR::computeAPPR(), TSnap::GetNodeWcc(), TSnap::GetTreeSig(), and TSnap::IsWeaklyConn().
|
inline |
|
inline |
|
inline |
Returns the value of the first element in the queue, but does not remove the element.
Definition at line 196 of file gbase.h.
Referenced by TSnap::CascFind(), TSnap::CascFindMP(), and MAPPR::computeAPPR().
|
private |
Definition at line 161 of file gbase.h.
Referenced by TSnapQueue< int >::Clr(), TSnapQueue< int >::Empty(), TSnapQueue< int >::Gen(), TSnapQueue< int >::GetFirst(), TSnapQueue< int >::Len(), TSnapQueue< int >::operator=(), TSnapQueue< int >::operator[](), TSnapQueue< int >::Pop(), TSnapQueue< int >::Push(), TSnapQueue< int >::Save(), and TSnapQueue< int >::Top().
|
private |
Definition at line 161 of file gbase.h.
Referenced by TSnapQueue< int >::Clr(), TSnapQueue< int >::Empty(), TSnapQueue< int >::Gen(), TSnapQueue< int >::GetLast(), TSnapQueue< int >::Len(), TSnapQueue< int >::operator=(), TSnapQueue< int >::Pop(), TSnapQueue< int >::Push(), and TSnapQueue< int >::Save().
|
private |
Definition at line 160 of file gbase.h.
Referenced by TSnapQueue< int >::Gen(), TSnapQueue< int >::operator=(), TSnapQueue< int >::Push(), and TSnapQueue< int >::Save().
|
private |
Definition at line 162 of file gbase.h.
Referenced by TSnapQueue< int >::Clr(), TSnapQueue< int >::Gen(), TSnapQueue< int >::operator=(), TSnapQueue< int >::operator[](), TSnapQueue< int >::Pop(), TSnapQueue< int >::Push(), TSnapQueue< int >::Reserved(), TSnapQueue< int >::Save(), and TSnapQueue< int >::Top().