I think Vincent Wolowski wrote:
[Charset iso-8859-1 unsupported, filtering to ASCII...]
> I use the following rule:
>
> rete.executeCommand("(defrule getFactIDofRootElement"+
> "(Tag (ParentID 0))"+
> "=>"+
> "(?factID <- (Tag (ParentID 0))))");
>
> If I use the return value, the value is true.
Well, yes. Defining a rule doesn't do anything; you'd have to run the
rule. Then you'd have to have the rule -do- something with the result,
to make it available to you in Java. You could use the store and fetch
functions; see manual section 4.4.4. The rule calls store, and then
you call fetch in Java. If you store ?factID, the Java object you
fetch will be a jess.FactIdValue.
It would be more appropriate, though, to use a defquery instead of a
rule here; see manual section 2.9.
---------------------------------------------------------
Ernest Friedman-Hill
Distributed Systems Research Phone: (925) 294-2154
Sandia National Labs FAX: (925) 294-2234
Org. 8920, MS 9012 [EMAIL PROTECTED]
PO Box 969 http://herzberg.ca.sandia.gov
Livermore, CA 94550
--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------