|
Query Cycle Simulator HEADER | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--qcsim.content.impl.ContentImpl
This object represents a given content category. It contains a files associated with the content category and is given to a peer as part of its shared data.
| Field Summary |
| Fields inherited from interface qcsim.content.Content |
BAD_FILE, GOOD_FILE |
| Constructor Summary | |
ContentImpl(int category)
Create a new content category |
|
| Method Summary | |
boolean |
addFile(int rank)
Add the file rank to this content category |
int |
category()
The content category id. |
java.lang.Object |
clone()
Create a copy of the current object |
boolean |
containsFile(int rank)
Search for the file rank in this content category |
boolean |
equals(java.lang.Object obj)
Does this content category equal the object. |
int |
files()
The number of files. |
double |
interest()
The peers interest level in this content category. |
void |
interest(double interest)
Set the peers interest level in this content category. |
void |
printContent()
Print the files contained in this content category. |
int |
volume()
The total volume of data (number of files) in this content category. |
void |
volume(int volume)
Set the total volume of data (number of files) in this content category |
| Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ContentImpl(int category)
category - identifies the content category| Method Detail |
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - The object/content category.public java.lang.Object clone()
clone in class java.lang.Objectpublic void printContent()
public int category()
category in interface Contentpublic double interest()
interest in interface Contentpublic void interest(double interest)
interest in interface Contentpublic int volume()
volume in interface Contentpublic void volume(int volume)
volume in interface Contentpublic int files()
files in interface Contentpublic boolean containsFile(int rank)
containsFile in interface Contentrank - the file to search.
public boolean addFile(int rank)
addFile in interface Contentrank - file to add.
|
Query Cycle Simulator HEADER | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||