genericArbiter.h

Go to the documentation of this file.
00001 
00030 #ifndef  _genericvcarbiter_h_INC
00031 #define  _genericvcarbiter_h_INC
00032 
00033 #include        <vector>
00034 #include        "../interfaces/arbiter.h"
00035 
00036 class GenericArbiter
00037 {
00038     public:
00039         GenericArbiter ();
00040         ~GenericArbiter();
00041         uint node_ip;
00042         uint address;
00043         string name;
00044         bool is_requested(uint ch);
00045         bool is_empty();
00046         void set_no_requestors( uint ch);
00047         void request( uint ch);
00048         uint get_no_requestors();
00049         uint pick_winner();
00050         string toString() const;
00051         void clear_winner();
00052 
00053     protected:
00054 
00055     private:
00056         uint vcs;
00057         vector < bool > requests;
00058         uint last_winner;
00059         bool done;
00060 
00061 }; /* -----  end of class genericvcarbiter  ----- */
00062 
00063 
00064 #endif   /* ----- #ifndef _genericvcarbiter_h_INC  ----- */
00065 
00066 

Generated on Tue Oct 19 17:22:00 2010 for IRIS by  doxygen 1.5.8