SNAP Library 6.0, User Reference
2020-12-09 16:24:20
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
|
Iterator class for TTable rows, that allows logical row removal while iterating. More...
#include <table.h>
Public Member Functions | |
TRowIteratorWithRemove () | |
Default constructor. More... | |
TRowIteratorWithRemove (TInt RowIdx, TTable *TablePtr) | |
Constructs iterator pointing to given row. More... | |
TRowIteratorWithRemove (TInt RowIdx, TTable *TablePtr, TBool IsStart) | |
Constructs iterator pointing to given row. More... | |
TRowIteratorWithRemove (const TRowIteratorWithRemove &RowI) | |
Copy constructor. More... | |
TRowIteratorWithRemove & | operator++ (int) |
Increments the iterator. More... | |
TRowIteratorWithRemove & | Next () |
Increments the iterator (For Python compatibility). More... | |
bool | operator< (const TRowIteratorWithRemove &RowI) const |
Checks if this iterator points to a row that is before the one pointed by RowI . More... | |
bool | operator== (const TRowIteratorWithRemove &RowI) const |
Checks if this iterator points to the same row pointed by RowI . More... | |
TInt | GetRowIdx () const |
Gets physical index of current row. More... | |
TInt | GetNextRowIdx () const |
Gets physical index of next row. More... | |
TInt | GetNextIntAttr (TInt ColIdx) const |
Returns value of integer attribute specified by integer column index for next row. More... | |
TFlt | GetNextFltAttr (TInt ColIdx) const |
Returns value of float attribute specified by float column index for next row. More... | |
TStr | GetNextStrAttr (TInt ColIdx) const |
Returns value of string attribute specified by string column index for next row. More... | |
TInt | GetNextIntAttr (const TStr &Col) const |
Returns value of integer attribute specified by attribute name for next row. More... | |
TFlt | GetNextFltAttr (const TStr &Col) const |
Returns value of float attribute specified by attribute name for next row. More... | |
TStr | GetNextStrAttr (const TStr &Col) const |
Returns value of string attribute specified by attribute name for next row. More... | |
TBool | IsFirst () const |
Checks whether iterator points to first valid row of the table. More... | |
void | RemoveNext () |
Removes next row. More... | |
TBool | CompareAtomicConst (TInt ColIdx, const TPrimitive &Val, TPredComp Cmp) |
Compares value in column ColIdx with given primitive Val . More... | |
Private Attributes | |
TInt | CurrRowIdx |
Physical row index of current row pointer by iterator. More... | |
TTable * | Table |
Reference to table containing this row. More... | |
TBool | Start |
A flag indicating whether the current row in the first valid row of the table. More... | |
Iterator class for TTable rows, that allows logical row removal while iterating.
|
inline |
Default constructor.
Definition at line 380 of file table.h.
Constructs iterator pointing to given row.
Definition at line 215 of file table.cpp.
|
inline |
Constructs iterator pointing to given row.
Definition at line 384 of file table.h.
|
inline |
Copy constructor.
Definition at line 387 of file table.h.
TBool TRowIteratorWithRemove::CompareAtomicConst | ( | TInt | ColIdx, |
const TPrimitive & | Val, | ||
TPredComp | Cmp | ||
) |
Compares value in column ColIdx
with given primitive Val
.
Definition at line 282 of file table.cpp.
Returns value of float attribute specified by float column index for next row.
Definition at line 252 of file table.cpp.
Returns value of float attribute specified by attribute name for next row.
Definition at line 265 of file table.cpp.
Returns value of integer attribute specified by integer column index for next row.
Definition at line 248 of file table.cpp.
Returns value of integer attribute specified by attribute name for next row.
Definition at line 260 of file table.cpp.
TInt TRowIteratorWithRemove::GetNextRowIdx | ( | ) | const |
Gets physical index of next row.
Definition at line 243 of file table.cpp.
Returns value of string attribute specified by string column index for next row.
Definition at line 256 of file table.cpp.
Returns value of string attribute specified by attribute name for next row.
Definition at line 270 of file table.cpp.
TInt TRowIteratorWithRemove::GetRowIdx | ( | ) | const |
Gets physical index of current row.
Definition at line 239 of file table.cpp.
TBool TRowIteratorWithRemove::IsFirst | ( | ) | const |
Checks whether iterator points to first valid row of the table.
Definition at line 274 of file table.cpp.
TRowIteratorWithRemove & TRowIteratorWithRemove::Next | ( | ) |
Increments the iterator (For Python compatibility).
Definition at line 222 of file table.cpp.
TRowIteratorWithRemove & TRowIteratorWithRemove::operator++ | ( | int | ) |
Increments the iterator.
Definition at line 218 of file table.cpp.
bool TRowIteratorWithRemove::operator< | ( | const TRowIteratorWithRemove & | RowI | ) | const |
Checks if this iterator points to a row that is before the one pointed by RowI
.
Definition at line 229 of file table.cpp.
bool TRowIteratorWithRemove::operator== | ( | const TRowIteratorWithRemove & | RowI | ) | const |
Checks if this iterator points to the same row pointed by RowI
.
Definition at line 235 of file table.cpp.
void TRowIteratorWithRemove::RemoveNext | ( | ) |
Removes next row.
Definition at line 278 of file table.cpp.
|
private |
|
private |
|
private |