Interface listFW.IListFactory


public interface IListFactory
extends Object
Abstract factory to manufacture IEmptyList and INEList.

Author:
Dung X. Nguyen, Stephen B. Wong

Method Index

 o makeEmptyList ()
Creates an empty list
 o makeNEList (Object, IList)
Creates a non-empty list containing a given first and a given rest

Methods

 o makeEmptyList
public abstract IEmptyList makeEmptyList()
Creates an empty list.

Returns:
an IEmptyList object.
 o makeNEList
public abstract INEList makeNEList(Object first, IList tail)
Creates a non-empty list containing a given first and a given rest.

Parameters:
first - a data object.
tail - the rest of the non-empty list to be manufactured.
Returns:
an INEList object containing first and tail