|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorca.cod.net.IPList
public class IPList
Simple allocator that stores a table of free and used IP addresses This may be used when IP address space is scarce and an entire SubnetBlock cannot be carved. It should be used on a per-site basis as opposed to per-Slice The allocate, release and reserve methods are synchronized because currently multiple slices can pull from and add to this list. In the future a policy for arbitrating sparse public IP address space could fix this, giving each slice its own space instead of sharing the same space.
| Field Summary | |
|---|---|
static java.lang.String |
PropertyFreeList
|
static java.lang.String |
PropertyTotal
|
static java.lang.String |
PropertyUsedList
|
| Constructor Summary | |
|---|---|
IPList()
Instantiate new Vectors for allocation of sparce IPs. |
|
| Method Summary | |
|---|---|
java.net.InetAddress |
allocate()
Allocate an IP address. |
void |
initialize()
Instantiate new Vectors for allocation of sparce IPs. |
boolean |
inList(java.net.InetAddress i)
|
void |
release(java.net.InetAddress i)
Release an ip address. |
void |
reserve(java.net.InetAddress i)
Indicate that an IP is reserved. |
void |
reset(java.lang.String s)
|
java.lang.String |
save()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.lang.String PropertyTotal
public static java.lang.String PropertyFreeList
public static java.lang.String PropertyUsedList
| Constructor Detail |
|---|
public IPList()
throws java.lang.Exception
total - All possible IP addresses to allocate from
java.lang.Exception| Method Detail |
|---|
public void initialize()
initialize in interface IInitializetotal - All possible IP addresses to allocate from
public java.net.InetAddress allocate()
throws java.lang.Exception
java.lang.Exception - if no free ip address.
public void release(java.net.InetAddress i)
throws java.lang.Exception
IP - to release
java.lang.Exception - if not being used
public void reserve(java.net.InetAddress i)
throws java.lang.Exception
IP - to be reserved
java.lang.Exceptionpublic boolean inList(java.net.InetAddress i)
public java.lang.String save()
throws java.lang.Exception
java.lang.Exception
public void reset(java.lang.String s)
throws java.lang.Exception
java.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||