X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=version2%2Fsrc%2FC%2FArbitrationRound.h;h=da1a2a8a2186e14e8b033401e9f250bee636bd3e;hb=b47765b628c0c160dd13622f8e241c377b8ce3cb;hp=7ef4a2eacf54ffc709171e13818baae9c04675bc;hpb=47ee5448a5177a43a6567626424c4ca25e2fd554;p=iotcloud.git diff --git a/version2/src/C/ArbitrationRound.h b/version2/src/C/ArbitrationRound.h index 7ef4a2e..da1a2a8 100644 --- a/version2/src/C/ArbitrationRound.h +++ b/version2/src/C/ArbitrationRound.h @@ -2,30 +2,32 @@ #define ARBITRATIONROUND_H #define MAX_PARTS 10 +#include "common.h" class ArbitrationRound { private: - Set * abortsBefore = NULL; - List * parts = NULL; - Commit commit = NULL; - int currentSize = 0; - bool didSendPart = false; - bool didGenerateParts = false; + Hashset * abortsBefore; + Vector * parts; + Commit * commit; + int currentSize; + bool didSendPart; + bool didGenerateParts; public: - ArbitrationRound(Commit * _commit, Set * _abortsBefore); + ArbitrationRound(Commit * _commit, Hashset * _abortsBefore); + ~ArbitrationRound(); void generateParts(); - List * getParts(); - void removeParts(List * removeParts); + Vector * getParts(); + void removeParts(Vector * removeParts); bool isDoneSending(); void setCommit(Commit * _commit); void addAbort(Abort * abort); - void addAborts(Set * aborts); - Set * getAborts(); + void addAborts(Hashset * aborts); + Hashset * getAborts(); int getAbortsCount(); int getCurrentSize(); bool isFull(); - bool didSendPart(); + bool getDidSendPart(); }; #endif