<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">/* **********************************************************************
 *
 *	Filename:	SkipListInterface.java  
 *
 *	Author:		Jason Howes
 *
 *	Notes:		CS 410 Assignment #8
 *	
 *	Date:		10/27/1998 (Modified on 4/4/99)
 *
 *	Notes:
 *
 *	This file contains an interface for a SkipList ADT.  The following
 *	functions are defined:
 *
 *		insert()
 *		delete()
 *		search()
 *		output()
 *
 *	SkipList implements this interface - you have to fill in the skeleton for SkipList.java
 *
 * **********************************************************************/

public interface SkipListInterface
{

	//////////////////////////////////////////////////////////////////////
	//
	//	SkipListInterface::insert()
	//
	//	Description:
	//		Inserts the key into the SkipList.
	//	
	//	Parameters:
	//		key:	Key to insert.
	//
	//	Returns:
	//		Nothing.
	//
	//////////////////////////////////////////////////////////////////////
	public void insert(int key);

	//////////////////////////////////////////////////////////////////////
	//
	//	SkipListInterface::delete()
	//
	//	Description:
	//		Deletes a key from a SkipList.
	//	
	//	Parameters:
	//		key:	Key to delete.
	//
	//	Returns:
	//		true if the delete was successful, false otherwise.
	//
	//////////////////////////////////////////////////////////////////////
	public boolean delete(int key);

	//////////////////////////////////////////////////////////////////////
	//
	//	SkipListInterface::search()
	//
	//	Description:
	//		Searches for a key in a SkipList.
	//	
	//	Parameters:
	//		key:	Key to search for.
	//
	//	Returns:
	//		The largest key in the SkipList &lt;= k, or -1 if no such key
	//		exits.
	//
	//////////////////////////////////////////////////////////////////////
	public int search(int key);
    //////////////////////////////////////////////////////////////////////
	//
	//	SkipListInterface::output()
	//
	//	Description:
	//		output the skip-list 
	//	
	//	Returns:
	//		the OutputList of this skip-list
	//		
	//
	//////////////////////////////////////////////////////////////////////
	public OutputList output();
}</pre></body></html>