se.ericsson.eto.norarc.javaframe
Class Database

java.lang.Object
  extended byse.ericsson.eto.norarc.javaframe.Database

public abstract class Database
extends java.lang.Object

A class that is a sketch of how a simple database e.g. for routing could be stuctured. The implementation is not useful if the speed of the database is of the essence


Constructor Summary
Database()
           
 
Method Summary
 java.lang.Object Access(java.lang.Object key)
          returns an Object from the Database that matches the given argument
 boolean Equals(byte[] a, byte[] b)
          utility to check whether two byte arrays have the same contents
 void Insert(java.lang.Object insrecord)
          inserts a given object into the database Any duplicates will be removed before the new element is inserted
protected  boolean Match(java.lang.Object key, java.lang.Object found)
          returns true if the two arguments match each other
 void Remove(java.lang.Object insrecord)
          removes an object from the database
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Database

public Database()
Method Detail

Match

protected boolean Match(java.lang.Object key,
                        java.lang.Object found)
returns true if the two arguments match each other


Access

public java.lang.Object Access(java.lang.Object key)
returns an Object from the Database that matches the given argument


Insert

public void Insert(java.lang.Object insrecord)
inserts a given object into the database Any duplicates will be removed before the new element is inserted


Remove

public void Remove(java.lang.Object insrecord)
removes an object from the database


Equals

public boolean Equals(byte[] a,
                      byte[] b)
utility to check whether two byte arrays have the same contents