package listFW.visitor; import listFW.*; /** * Copies an IList using the an IListFactory supplied as an input parameter * @author Mathias Ricken - Copyright 2008 - All rights reserved. */ public class CopyList3 implements IListAlgo, IListFactory> { public IMTList emptyCase(IMTList host, IListFactory ... fac) { return fac[0].makeEmptyList(); } public INEList nonEmptyCase(INEList host, IListFactory ... fac) { return fac[0].makeNEList( host.getFirst(), host.getRest().execute(this, fac)); } }