|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object anon.tor.ordescription.ORList
public final class ORList
Field Summary | |
---|---|
private java.util.Date |
m_datePublished
|
private java.util.Vector |
m_exitnodes
|
private java.util.Vector |
m_middlenodes
|
private java.util.Vector |
m_onionrouters
|
private java.util.Hashtable |
m_onionroutersWithNames
|
private ORListFetcher |
m_orlistFetcher
|
private MyRandom |
m_rand
|
private static java.text.DateFormat |
ms_DateFormat
|
Constructor Summary | |
---|---|
ORList(ORListFetcher fetcher)
constructor |
Method Summary | |
---|---|
ORDescription |
getByName(java.lang.String name)
gets an onion router by it's name |
ORDescription |
getByRandom()
selects a OR randomly |
ORDescription |
getByRandom(int length)
selects a OR randomly tries to blanace the probability of exit and non-exit nodes |
ORDescription |
getByRandom(java.util.Vector allowedNames)
selects a OR randomly from a given list of allowed OR names |
java.util.Vector |
getList()
returns a List of all onionrouters |
ORDescription |
getORDescription(java.lang.String name)
returns a ORDescription to the given ORName |
java.util.Date |
getPublished()
gets the date when the List was pubished |
private boolean |
parseDocument(byte[] strDocument)
parses the document and creates a list with all ORDescriptions |
void |
remove(java.lang.String name)
removes an onion router |
void |
setFetcher(ORListFetcher fetcher)
|
int |
size()
size of the ORList |
boolean |
updateList()
Updates the list of available ORRouters. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.util.Vector m_onionrouters
private java.util.Vector m_exitnodes
private java.util.Vector m_middlenodes
private java.util.Hashtable m_onionroutersWithNames
private MyRandom m_rand
private ORListFetcher m_orlistFetcher
private java.util.Date m_datePublished
private static final java.text.DateFormat ms_DateFormat
Constructor Detail |
---|
public ORList(ORListFetcher fetcher)
Method Detail |
---|
public int size()
public void setFetcher(ORListFetcher fetcher)
public boolean updateList()
public java.util.Vector getList()
public java.util.Date getPublished()
public ORDescription getByName(java.lang.String name)
name
- name of the OR
public void remove(java.lang.String name)
name
- name of the ORpublic ORDescription getByRandom(java.util.Vector allowedNames)
orlist
- list of onionrouter names
public ORDescription getByRandom()
public ORDescription getByRandom(int length)
length
- length of the circuit
public ORDescription getORDescription(java.lang.String name)
name
- ORName
private boolean parseDocument(byte[] strDocument) throws java.lang.Exception
strDocument
-
java.lang.Exception
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |