Jess Information

Jess Home
Jess 7 Features
Download Now!
Online Demo

Documentation
FAQ
Manual
Mailing List
Jess Wiki

More information Related Web Sites
User Contributions
JSR94 Info
Developer's Log
About This Site

JESS ®, the Rule Engine for the JavaTM Platform

Jess Wiki: Next Agenda

(deffunction next-agenda ()
    "List the agenda of the next module with a non-empty agenda"
    (bind ?I 1)
    (bind ?FOCUS_STACK (get-focus-stack))
    (while
        (and
            (<= ?I (length$ ?FOCUS_STACK))
            (not (((engine) listActivations (nth$ ?I ?FOCUS_STACK)) hasNext))
        )
        (bind ?I (+ ?I 1)))
    (if (<= ?I (length$ ?FOCUS_STACK))
        then (agenda (nth$ ?I ?FOCUS_STACK))
        else (agenda MAIN))
    (printout t "Focus Stack: " ?FOCUS_STACK crlf))

Submitted by:
GeorgeWilliamson
Union Pacific Railroad
gawillia@up.com



DebuggingTips


Front Page | Sandbox | Recent Changes | Powered by Friki | Last Edited: 18 August 2006