net.jolsrv2.repository.neighbourhood
Class NaaSet

java.lang.Object
  extended by net.jolsrv2.repository.neighbourhood.NaaSet

public final class NaaSet
extends java.lang.Object

The class implements the neighbour address association set, as specified in OLSRv2.

Author:
Andreas Schjønhaug

Method Summary
 java.lang.Object clone()
          Implementation of the singleton design pattern.
static NaaSet getNaaSet()
          Implementation of the singleton design pattern
 java.util.ArrayList<NaaTuple> getTuples()
          Returns the neighbour address association tuples
 boolean populate(long intervalTime, java.util.ArrayList<CidrAddress> cidrAddresses)
          Method for populating the neighbour address association set
 void purge()
          The method purges the neighbour address association set, deleting expired entries
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getNaaSet

public static NaaSet getNaaSet()
Implementation of the singleton design pattern

Returns:
the neighbour address association set

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Implementation of the singleton design pattern. This method is used to ensure that the class can not be cloned.

Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

populate

public boolean populate(long intervalTime,
                        java.util.ArrayList<CidrAddress> cidrAddresses)
Method for populating the neighbour address association set

Parameters:
intervalTime - the interval time
cidrAddresses - the CIDR addresses
Returns:
true if a change is detected

purge

public void purge()
The method purges the neighbour address association set, deleting expired entries


getTuples

public java.util.ArrayList<NaaTuple> getTuples()
Returns the neighbour address association tuples

Returns:
the neighbour address association tuples