gnu.prolog.vm.buildins.list
Class Predicate_append
java.lang.Object
   gnu.prolog.vm.ExecuteOnlyCode
gnu.prolog.vm.ExecuteOnlyCode
       gnu.prolog.vm.buildins.list.Predicate_append
gnu.prolog.vm.buildins.list.Predicate_append
- All Implemented Interfaces: 
- Installable, PrologCode
- public class Predicate_append 
- extends ExecuteOnlyCode
TODO
 
 Does:
 
 
 %append(?HeadList, ?TailList, ?List)
 append([],X,X).
 append([X|Xs],Y,[X|Z]) :- append(Xs,Y,Z).
 
 
 But without recursion
- Author:
- Daniel Thomas based on Predicate_member by Michiel Hendriks
 
 
 
 
 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
Predicate_append
public Predicate_append()
execute
public int execute(Interpreter interpreter,
                   boolean backtrackMode,
                   Term[] args)
            throws PrologException
- Description copied from interface: PrologCode
- this method is used for execution of code
 
- 
- Specified by:
- executein interface- PrologCode
- Specified by:
- executein class- ExecuteOnlyCode
 
- 
- Parameters:
- interpreter- interpreter in which context code is executed
- backtrackMode- true if predicate is called on backtracking and false otherwise
- args- arguments of code
- Returns:
- either SUCCESS, SUCCESS_LAST, or FAIL.
- Throws:
- PrologException
 
nextSolution
protected int nextSolution(Interpreter interpreter,
                           Predicate_append.AppendBacktrackInfo bi)
                    throws PrologException
- 
- Parameters:
- interpreter-
- bi-
- Returns:
- PrologCode return code
- Throws:
- PrologException