DNet
Class HostBase

java.lang.Object
  |
  +--DNet.HostBase

public class HostBase
extends java.lang.Object


Field Summary
static int DNET
           
static int GNUTELLA
           
private  java.util.LinkedList hosts
           
private static HostBase inst
           
private  int maxHosts
           
private  int minHosts
           
private static int N_TYPES
           
private  int pos
           
 
Constructor Summary
private HostBase()
           
 
Method Summary
 void addHost(HostNode host)
           
 void addHost(int type, java.lang.String ip, int port)
           
static HostBase init()
           
static HostBase instance()
           
 boolean isFull()
           
 boolean load()
           
 HostNode next()
           
 void removeHost(HostNode host)
           
 void removeHost(int type, java.lang.String ip, int port)
           
 void reset()
           
 boolean save()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

GNUTELLA

public static final int GNUTELLA

DNET

public static final int DNET

N_TYPES

private static final int N_TYPES

hosts

private java.util.LinkedList hosts

pos

private int pos

inst

private static HostBase inst

minHosts

private int minHosts

maxHosts

private int maxHosts
Constructor Detail

HostBase

private HostBase()
Method Detail

reset

public void reset()

next

public HostNode next()

instance

public static HostBase instance()

init

public static HostBase init()

addHost

public void addHost(HostNode host)

addHost

public void addHost(int type,
                    java.lang.String ip,
                    int port)

removeHost

public void removeHost(HostNode host)

removeHost

public void removeHost(int type,
                       java.lang.String ip,
                       int port)

isFull

public boolean isFull()

load

public boolean load()

save

public boolean save()