package list.dl.algo; import list.dl.DLList; /** * Returns the left end list. */ public class GetLeftEnd implements IAlgoLeft { final public static GetLeftEnd Singleton = new GetLeftEnd(); private GetLeftEnd() { } /** * @param hostList * @param inputParam * @return */ public Object leftEndCase(DLList hostList, Object inputParam) { return hostList; } /** * @param hostList * @param inputParam * @return */ public Object dataNodeCase(DLList hostList, Object inputParam) { return hostList.getLeftRest ().executeLeft (this, null); } }