Skip to content

Commit

Permalink
Added QX::headIndex(), and QX::tailIndex() stubs.
Browse files Browse the repository at this point in the history
  • Loading branch information
CFB-QUBIC committed Mar 25, 2024
1 parent 68487fe commit 676189b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/smart_contracts/qpi.h
Original file line number Diff line number Diff line change
Expand Up @@ -5602,6 +5602,12 @@ namespace QPI
return povIndex < 0 ? NULL_INDEX : _povs[povIndex].headIndex;
}

// Return elementIndex of first element with priority <= maxPriority in priority queue of pov (or NULL_INDEX if pov is unknown).
sint64 headIndex(const id& pov, sint64 maxPriority) const
{
return NULL_INDEX; // TODO: Implement
}

// Return elementIndex of next element in priority queue (or NULL_INDEX if this is the last element).
sint64 nextElementIndex(sint64 elementIndex) const
{
Expand Down Expand Up @@ -5766,6 +5772,12 @@ namespace QPI

return povIndex < 0 ? NULL_INDEX : _povs[povIndex].tailIndex;
}

// Return elementIndex of last element with priority >= minPriority in priority queue of pov (or NULL_INDEX if pov is unknown).
sint64 tailIndex(const id& pov, sint64 minPriority) const
{
return NULL_INDEX; // TODO: Implement
}
};

//////////
Expand Down

0 comments on commit 676189b

Please sign in to comment.