/*
 * Created on 2004-10-19
 *
 * To change the template for this generated file go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
package org.huihoo.willow.store;

import java.util.Enumeration;
import java.util.Hashtable;

/**
 * @author reic
 *
 * To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
public class DatabaseEntries
{
	private Hashtable databaseEntries = new Hashtable(10);
	
	public void addDatabaseEntry(DatabaseEntry entry)
	{
		if(entry==null || entry.getVendor()==null || entry.getDriver()==null)
		{
			return;
		}
		
		databaseEntries.put(entry.getVendor(),entry);
	}
	
	public Enumeration entries()
	{
		return databaseEntries.keys();
	}
	
	public DatabaseEntry findDatabaseEntry(String vendor)
	{
		return (DatabaseEntry)databaseEntries.get(vendor);
	}
}
