GAMS  1.4.0
gams::elections Namespace Reference

Provides voting mechanisms for distributed elections. More...

Classes

class  ElectionBase
 Base class for an election. More...
 
class  ElectionCumulative
 An election that implements cumulative voting. More...
 
class  ElectionCumulativeFactory
 Factory for creating plurality elections. More...
 
class  ElectionFactory
 Base class for an auction factory. More...
 
class  ElectionFactoryRepository
 A repository for election factories. More...
 
class  ElectionPlurality
 An election that implements plurality voting(NOT IMPLEMENTED) More...
 
class  ElectionPluralityFactory
 Factory for creating plurality elections. More...
 

Typedefs

typedef std::vector< std::string > CandidateList
 list of candidates More...
 
typedef std::map< std::string, madara::knowledge::KnowledgeRecord::Integer > CandidateVotes
 candidate vote tally More...
 
typedef std::map< ElectionType, ElectionFactory * > ElectionFactoryMap
 Convenience typedef for a map of types to factories. More...
 
typedef madara::knowledge::KnowledgeRecord::Integer ElectionType
 convenience typedef for ElectionType More...
 

Enumerations

enum  ElectionTypes { ELECTION_PLURALITY = 0 , ELECTION_CUMULATIVE = 1 , NUM_ELECTION_TYPES = 2 }
 Known group types. More...
 

Detailed Description

Provides voting mechanisms for distributed elections.

Typedef Documentation

◆ CandidateList

typedef std::vector<std::string> gams::elections::CandidateList

list of candidates

Definition at line 73 of file ElectionBase.h.

◆ CandidateVotes

typedef std::map<std::string, madara::knowledge::KnowledgeRecord::Integer> gams::elections::CandidateVotes

candidate vote tally

Definition at line 77 of file ElectionBase.h.

◆ ElectionFactoryMap

Convenience typedef for a map of types to factories.

Definition at line 71 of file ElectionFactoryRepository.h.

◆ ElectionType

typedef madara::knowledge::KnowledgeRecord::Integer gams::elections::ElectionType

convenience typedef for ElectionType

Definition at line 81 of file ElectionTypesEnum.h.

Enumeration Type Documentation

◆ ElectionTypes

Known group types.

Enumerator
ELECTION_PLURALITY 
ELECTION_CUMULATIVE 
NUM_ELECTION_TYPES 

Definition at line 72 of file ElectionTypesEnum.h.