|
Query Cycle Simulator HEADER | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--qcsim.impl.InitializationManagerImpl
Creates and initializes system components.
| Constructor Summary | |
InitializationManagerImpl(QueryCycleManager manager)
Constructor |
|
| Method Summary | |
void |
content(int categories,
int minCategories,
int distribution)
This is used to establish the desired content parameters. |
void |
errorFraction(double error,
int type)
This will setup the upload error fraction for a given type of peer. |
void |
establishCollective(java.util.Vector peers,
int collective,
int type)
This method is used to establish malicious collectives. |
void |
goodPeerResponseSelector(int selector)
This method will setup the method of choosing which responses each good peer chooses to download. |
void |
highTrustPeerCategoryPref(int pref)
This method will setup highly trusted peers to have extra category preference. |
void |
maliciousPeerCategoryPref(int pref)
This method will setup malicious peers to have extra category preference. |
PeerManager |
peerManager()
This module is responsible for initializing the peer manager. |
void |
peers(int gp,
int gpn,
int mp,
int mpn,
int htp,
int htpn)
This function will setup the number of desired peers in the system. |
void |
setPeerActivity(java.util.Vector peers,
int activity)
This will setup the peer's activity during the simulation. |
Simulator |
simulator()
This module is responsible for initializing the simulator. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public InitializationManagerImpl(QueryCycleManager manager)
| Method Detail |
public void peers(int gp,
int gpn,
int mp,
int mpn,
int htp,
int htpn)
peers in interface InitializationManagergp - The number of good peers.gpn - The number of neighbors each good peer should have.mp - The number of malicious peers.mpn - The number of neighbors each malicious peer should have.htp - The number of highly trusted peers.htpn - The number of neighbors each highly trusted peers should have.
public void content(int categories,
int minCategories,
int distribution)
content in interface InitializationManagercategories - The total number of categories in the system.minCategories - Each peer will maintain at least this number of categories.distribution - Specifies how files are distributed among peers.public void maliciousPeerCategoryPref(int pref)
maliciousPeerCategoryPref in interface InitializationManagerpref - The type of preferencepublic void highTrustPeerCategoryPref(int pref)
highTrustPeerCategoryPref in interface InitializationManagerpref - The type of preferencepublic void goodPeerResponseSelector(int selector)
goodPeerResponseSelector in interface InitializationManagerselector - response selector (see PeerBehavior.RPB_*).
public void errorFraction(double error,
int type)
errorFraction in interface InitializationManagererror - The fraction of time a peer makes a mistake.type - The type of peer that has this error fraction.
public void setPeerActivity(java.util.Vector peers,
int activity)
setPeerActivity in interface InitializationManagerpeers - A vector of peers to initialize.activity - The activity model the peers will follow.
public void establishCollective(java.util.Vector peers,
int collective,
int type)
establishCollective in interface InitializationManagerpeers - The peers that will be apart of the collective.collective - The colletive type.type - The type of configuration.public PeerManager peerManager()
peerManager in interface InitializationManagerpublic Simulator simulator()
simulator in interface InitializationManager
|
Query Cycle Simulator HEADER | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||