Please attach your (rule) source.
You don't provide much for the community to go on.
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Libor Nenadál
Sent: 13 November 2009 13:59
To: rule
If you are checking for class in the LHS would it not be better to
define a separate rule for the subclass?
I assume you're doing something like:-
rule "current"
when
MyClass(class == MySubClassOfMyClass.class)
then
//Something specific to the subclass
end
When som
Hi Wolfgang,
I'm interested with your reply and am trying to better understand it (although
the use-case has nothing to do with what I do!)
The Score class has a constructor taking Deal and level (assume to be akin to
"priority" in the original post); however your example Fact insertions excl
You could look into using a sequential RETE network
http://blog.athico.com/2007/07/sequential-rete.html
http://www.redhat.com/docs/manuals/jboss/jboss-soa-4.2/html/JBoss_Rules_
Manual/ch02s05s10.html
But as Greg suggests, better understanding your use-case might furnish
other ideas.
-Origi
Can I just clarify that you *need* truth maintenance on the inserts but not on
the retractions?
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Greg Barton
Sent: 16 September 2009 21:28
To: Rules Users List
Subject:
;-)
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Jaroslaw
Kijanowski
Sent: 16 September 2009 09:41
To: Rules Users List
Subject: Re: [rules-users] Applying rules on xml data
Hi,
you will need to create POJOs out
Hi Nilima,
This might be of interest
http://www.theserverside.com/discussions/thread.tss?thread_id=46708
although I don't know whether it is supported with Drools 5.x.
Otherwise I believe your only option is to use JAXB to map the XML into
POJO's. I am unsure whether there is a native channel i
Let me understand you better.
The events do not contain any information about source other than what
can be implied from their temporal position?
Source 1 : 0s, 15s, 30s, 35s etc
Source 2: 5s, 20s, 35s, 40s etc
What if the period between events for a specific source were greater
than 15s (as you
what version of Drools are you using?
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Vikram
Pancholi
Sent: 27 August 2009 15:30
To: rules-users@lists.jboss.org
Subject: [rules-us
I assume "...but when I change a field of a db-record manually..." means you go
into the database and tweak a field?
In which case this is definitely a hibernate session usage issue and I'd
suggest you read up on the latter.
With kind regards,
Mike
-Original Message-
From: rules-user
If each rule is held within a unique agenda, you could use agenda
filters.
How would you determine which rule needs to be activated though? You'd
need some criteria hard-coded elsewhere in your application. Why not
make this part of the rules too?
From:
Why not simply use something like this:-
rule "TaxCalc"
when
$i : Invoice($st : salesTax, $gst : gstRate, $sa : salesAmount,
$id : importDuty, $gr : govtRebate)
then
$i.setTotalTax(round($st + ($gst * $sa / 100) + $id - $gr, 2));
update($i);
end
What do you gai
I believe you will need to add each DRL file into a single RuleBase
(Drools 4.x terminology; I think KnowledgeBase in 5.0 but I'm a little
rusty).
Don't forget rules aren't evaluated when "fireAllRules" is called but as
objects are inserted into WorkingMemory, so all rules need to be
compiled int
http://www.jboss.org/drools/lists.html
Finally, do read the documentation, you would probably be able to answer
your own questions.
With kind regards,
Mike
From: Amila Silva [mailto:ami...@hsenidmobile.com]
Sent: 23 June 2009 10:58
th el-api.
Bingo now all 3 guvnor ,drools-server ,and my web-client application are
deployed in tomcat 6 and working fine.
Still in need of a document describing ,the complete working of the rest
api
along with the web client to call drools server.
Thanks
Tanzu
Anstis, Michael (M.) wrote:
>
&
$f, $t, $p);
end
Still not sure if a rules engine is your best option, if I understand
your use case correctly.
From: Anstis, Michael (M.)
Sent: 23 June 2009 10:00
To: 'ami...@hsenidmobile.com'; 'Rules Users List'
Let me see if I understand correctly.
You want the user to be able to define the SQL query (table, field list,
predicates) and have the resulting SQL executed within Drools?
Is this your only requirement for the rules engine; if so have you
thought a rules engine might not be your best option.
Did you replace the EL jar with that available from JBOSS?
You will still need an EL jar somewhere if you are using JSF.
Do you have Java security enabled in your Tomcat instance? I've
previously had to put the EL jar in Tomcat's lib folder to fix other
issues relating to the use of JSF and EL on
You have not clearly defined when you want to execute SQL queries.
If you want to access a DB from the LHS you can use the "from" keyword.
Note the results need to be time-constant i.e. not change on successive
calls.
If you want to access a DB from the RHS it is plain Java (or MVEL
depending u
You need to provide more information.
Your question is like me replying with "I don't have any problems".
Not very helpful.
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of SHIMI
Abdelouahad ( Prestataire )
Sent: 22
Your jpg was not visible at the enclosed URL.
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of rajakanthan
Sent: 23 June 2009 02:24
To: rules-users@lists.jboss.org
Subject: [rules-users] forEach node Clarification
Hey
Correct me if I misunderstand:-
(1) You have a list of Strings accessible using a generic "businessData"
property.
(2) Nestled within the list *you happen to know* one of the values
represents a SSN and another the loan amount.
(3) You expect Drools to read your mind and workout how to determine
I believe the answer is that Drools implements sub-rule compilation for
rules containing "or".
So in essence your rulebase contains the following once compiled:-
rule "fire_twice_a"
no-loop true
when
eval(true)
then
System.out.println("word");
end
rule "fire_twice_b"
Perhaps, as Otter suggested, you provide a little more information about
what you are trying to achieve?
Rene,
mhhm, what are your trying to do (besides storing rules in a rdbms)?
What's the use-case?
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun
This might be of interest http://www.jboss.org/community/docs/DOC-11909
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of JohnSood
Sent: 30 March 2009 13:20
To: rules-users@lists.jboss.org
Subject: [rules-users] How to u
This looks like a JPA issue; have you configured your PersistenceUnit?
I haven't used EclipseLink but in other IDE's you can create a PU
graphically. There's always persistence.xml to fall back to as well.
Looks like EclipseLink can't find a PU definition.
Lets think about your new question logically.
A CPU cannot give more than 100% utilisation. If Drools is consuming 80% and
other applications require less than 20% then the other applications
performance will not degrade. If however the other applications require more
than 20% CPU utilisation t
I read that JBoss AS supports JRuby classes running in the JVM...
http://oddthesis.org/posts/2009-03-jboss-rails-1-0-0-beta4-in-time-for-t
he-weekend
Whilst I haven't used it nor read about it in detail perhaps this is
something that might be of interest.
With kind regards,
Mike
_
You could consider Agenda Groups.
You could either bunch groups of rules into discrete sets or have each
rule in its own Agenda Group.
You would then use workingMemory.setFocus(...) before calling
fireAllRules().
This is based upon 4.x and so could be different in 5 (which I haven't
had time
Furthermore a rulebase can contain rules from many resources (e.g.
DRL's).
So I guess the cause of your pain is why do you need multiple
rulebases!??!
-Original Message-
From: rules-users-boun...@lists.jboss.org
[mailto:rules-users-boun...@lists.jboss.org] On Behalf Of Scott Reed
Sent: 1
t is
possible through RETE algo used inside drools or should i do it
on
my own of identifying the rules...
Anstis, Michael (M.) wrote:
>
> I concur everybody's statements fully.
>
> The purpose of a rules engine is to remove the need for the
application
> developer
I concur everybody's statements fully.
The purpose of a rules engine is to remove the need for the application
developer to code algorithms to determine which of a set of rules should
execute given a set of facts\properties\objects. Drools implements the
RETE algorithm. Writing your own code to de
This isn't really anything to do with Drools though.
Drools rules could simply use "from" to invoke methods on a proxy that
hides your mainframe connectivity (which would be the same for any Java
application).
From: rules-users-boun...@lists.jboss.org
[
The RHS is just a block of Java, do what you like.
There is an implicit variable drools available in the RHS that equates
to an instance of KnowledgeHelper.
(This was 4.x - Hundson doesn't show a KnowledgeHelper for 5 so I'm
guessing things have changed).
-Original Message-
From: rules-
Do you mean object classes that represent DRL or objects that DRL
operate upon (i.e. Facts)?
Facts are simply POJO's and therefore IMO any mechanism that can
deserialise into a POJO should suffice.
You could also look into the use of JNI for the interface between C++
and Drools.
With kind re
Hello,
Unless the Drools team have a "secret optimisation" *I think* there is
no other way to insert large numbers of facts.
Think about it; every fact you insert will need to be propagated through
the RETE network in order for the correct rules to be activated.
You could however optimise your r
Hi,
A "Swim lane" is a term associated with UML Activity diagrams where the
activities undertaken by certain actors are grouped into lanes.
Here's the first Google result I found...
http://www.jiscinfonet.ac.uk/InfoKits/process-review/process-review-9.5
With kind regards,
Mike
_
Thanks,
David
On Thu, Jan 29, 2009 at 5:57 AM, Anstis, Michael (M.)
wrote:
Hi David,
Sorry it was of little help.
easoner(Calendar.getInstance()).lessThan($expires))
then
// do something for when credit card is still valid
end
Now, I'm still generally a noob with BRs, so I'm not sure how
this will affect performance. Any advice?
Than
xb-runtime
-streaming-xpath-implementation-and-more/
Can you enlighten me with your knowledge of XML Streaming in Drools?
From: Gupta, Ankit (Ankit) [mailto:gupt...@avaya.com]
Sent: 29 January 2009 10:04
To: Anstis, Michael (M.)
Subject:
Received from Anit, which might help others comment
From: Gupta, Ankit (Ankit) [mailto:gupt...@avaya.com]
Sent: 29 January 2009 10:04
To: Anstis, Michael (M.)
Subject: RE: [rules-users] Parsing XML using Drools
Hi,
I wonder whether Drools 5 "Complex Event Processing Support (Temporal
Reasoning)" might be what you're looking for?
http://blog.athico.com/2008/07/drools-50-m1-new-and-noteworthy.html
With kind regards,
Mike
From: rules-users-boun...@lists.jbo
It is not clear how you want to use the XML?
If the XML represents Facts then you could use a worker Fact and "FROM"
to deserialise them and make them available to WM. For example:-
rule "get some XML facts"
when
$w : Worker()
Cheese( ) from $w.getCheesesFromXML();
then
I wonder whether a custom accumulate function could be used to move your
logic out of the object model?
Not that accumulate was (probably) meant for this sort of function but
the "init" method could create the empty set and "accumulate" perform
your iteration below?
Just the musing of an idle m
Rules that are not in any explicit user-defined Agenda Group belong
implicitly to the MAIN Agenda Group which is the last Agenda Group to
trigger activations when all others have completed. Provided ALL of your
rules belong to an explicit Agenda Group you should be able to
setFocus(...) to Group A
e don't want to execute a
group
of rules if a rule A is not matched : in that group of rules : those
which
all paterns match LHS will be inevitably executed.
>>> Wrong. The rules won't be executed (read as activations - RHS -
won't be run) but you can't stop the LHS bei
Please accept that my knowledge is based on 4.x and there might be other
alternatives in 5.
Rules are not "ran" but their patterns (LHS) evaluated as facts
(objects) are inserted into Working Memory. When all patterns in the LHS
of a rule are matched activations are placed on the agenda for execut
I unwrapped my Christmas present early to find that the image links in
the documentation are unfortunately broken in the downloads. I haven't
tried from SVN. :-(
For example
file:///C:/etirelli/workspace/jboss/jbrules-trunk/drools-docs/drools-doc
s-guvnor/en/Chapter-Guvnor/NewMainScreen.png
Obv
You might need to add the MemberDataRecords into WM and use not exists
when
$d : Data()
$mdr : MemberDataRecord( $d1 : loggedInDate )
not exists MemberDataRecord ( loggedInDate > $d1 )
then
//Smurf
end
From: [EMAIL PROTECTED]
[mailto
What version of Drools are you using?
Pre-5 has "Shadow Facts" so you can't rely upon pass-by-reference. I
believe 5 has had Shadow Facts removed.
Insert places a new object into WM whereas update refreshes (the shadow)
of an existing one.
I would expect you to have to use update in your exam
You could use a global as OutputObject instead of a Fact.
If you want to use properties of OutputObject in a LHS pattern you'll
need to use "from" but this is not indexed and so using the two rules
with a fact approach might give better performance in this case.
Please don't cross post: http://www.jboss.org/drools/lists.html
IMO, Drools can do what you want but you need to change the way you are
thinking about the problem.
The behaviour you consider undesirable is by design as all patterns
(i.e. conditions) need to be matched for the consequence to acti
Why not add your ArrayList items individually into WM?
rule "P1 110"
salience 1
activation-group "1"
when
PriorityType( pricetype == "10,20,30,40,110" )
t:TlbObjectAttributeData( lngAttrTypeId == 110 )
then
result.add(t);
end
Would this not gi
ert)?
Again, really appreciate your answers a lot!Thanks
Paul
Anstis, Michael (M.) wrote:
>
> OK, so here is my take on things:-
>
> +--+ ++ +---+
> | | || | |
> | Sub-syste
OK, so here is my take on things:-
+--+ ++ +---+
| | || | |
| Sub-system 1 |-->| Sub-system 2 |-->| Sub-system 3 uses |
| sets up data | | Rules \ Drools | | results from sub- |
+--
Hi Paul,
What about subclassing List and adding a "type" attribute?
class MyArrayList extends ArrayList {
private String type;
public String getType() {
return type;
}
}
Rule "smurf"
when
$l : MyArrayList( type == 'shirt' )
Hi psentosa,
I don't fully understand what you require, but won't using a List of
WashRuleMatches provide what you need?
rule A
when
$s : Shirt (dirtinessLevel == high)
$holder : WashRuleValueHolder()
Then
System.out.println ("this cloth should be washed in 60 degree
water wit
_
De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] De la part de Anstis,
Michael (M.)
Envoyé : vendredi 8 août 2008 17:36
À : Rules Users List
Objet : RE: [rules-users] Use of a DAO in LHS
I suspect you may not have read the documen
I suspect you may not have read the documentation.
Take a look at the "from" keyword.
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of BINET
JEAN-BAPTISTE
Sent: 08 August 2008 16:01
To: rules-users@lists.jboss.org
S
Section "2.2. Why use a Rule Engine" in the documentation gives a wealth
of extra information that I forgot about first time round!
-Original Message-----
From: Anstis, Michael (M.)
Sent: 08 August 2008 09:07
To: 'Rules Users List'
Subject: RE: [rules-users] Drools vs B
Well, IMO, common sense suggests highly specialised hand crafted code
optimised to a particular problem domain *should* be faster than a
generic algorithm (taking this further why not dump the high level
languages all together and opt for C++ or assembler, if you really
really want you squeeze perf
I think you might need to post more of your source if possible.
Where are you setting PoolInfo.daysBeforeSummons to 5, outside WM and
before fireAllRules or within the RHS of another rule?
Thanks,
Mike
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Heh
Hi Mark,
A few questions:-
(A) What does "parallel evaluation of a rulebase" mean? Is it designed
to optimise, for example, two threads processing a stateless and
stateful session?
(B) Are there only two partitions, both of which are invisible to the
user? Is there any value in allowing user-def
orkingMemory
Thanks for the prompt response.
In the example bellow one can see that list1 items are actually passed to
the execute() method. Hence the dilema whether the engine will look at the
WM or at the global. to my understanding, it will loop on the global. I just
want to be sure that I un
I believe the "from" keyword will iterate only the items in list1.
I don't consider it naïve though; just doing what it is documented to do.
If you want to iterate facts in the RETE network you need to insert them into
working memory.
You could use a rule to do this (copy from a global into WM)
Do you use a stateful session?
Are your measurements before and after you've inserted facts into
working memory?
Would be helpful to the group to post your use-case source?
Thanks,
Mike
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf O
You can use any technology you like to get data from outside the Working
Memory using the "from" keyword.
Look at the documentation for more details.
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of thomas kukofka
Sent: 28 July 200
drools.getworkingmemory.startprocess(id) "Starts a new process instance
for the process with the given id."
Section "6.8.4. Using a rule flow in your application" of the (4.0.5)
manual gives more information.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf O
Hi Ron,
Have a look at the "Alarms" example for "Collect" in the (4.0.5) manual.
This should give you a good starting point.
Cheers,
Mike
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ron Kneusel
Sent: 22 July 2008 23:01
To: rules-users@lists.jboss.o
Cross posted for information.
Ths subject is more for the user list than the dev' one.
Cheers,
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of 9Lives 9Lives
Sent: 14 July 2008 14:33
To: Rules Dev List
Subject: RE
I wonder whether is's a "benefit" of truth maintenance? If a new fact is
inserted into working memory that could cause an activation of a rule
that contains an accumulate (or collect) to change then the whole
accumulate (or collect) operator is executed again?!?
-Original Message-
From: [E
searched through the doc for drools, and the email archive, there is
really no good example or explanation on how to achieve this.
(What I want is to insert, select or delete some objects in relational
database such as mysql.)
Any information is greatly appreciated.
Thanks.
On Tue, Jul 8, 2008 at
Hi,
Given the rule you show it doesn't matter how many records you have on a
table UNLESS they are inserted into working memory. So, assuming you
have code outside of that below which inserts each individual record
into working memory, then you can expect one activation to appear on the
agenda fo
Have a look at an example posted earlier this week whereby somebody
(sorry I forget who) was using JPA from within a rule.
Once you understand how JPA was used then the remaining questions relate
more specifically to JPA.
As Mark says, (native) Hibernate can also be used very easily.
With kind r
Keyword "From" allows for the retrieval of facts from outside the rule
engine, whereas "memberOf" works upon fact attributes.
So these would (should!) be other alternatives:-
when
$p : Property() from (em.createNativeQuery("select PROP from
SAMPLEOBJECT").getResultList()))
SampleObject(
Hi,
Rules are not executed as Facts are inserted into Working Memory.
Basically, think of the Working Memory as a network of connected classes
("The RETE network"). As facts are inserted into Working Memory they
enter the top of the network and propagate through it depending upon the
patterns wit
Somewhat better than my reply, now where was that stone I crawled from
under? ;-)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Kris Verlaenen
Sent: 26 June 2008 15:49
To: Rules Users List
Subject: Re: [rules-users] Stateless session and rule flows
Use
Hi,
I believe Stateless session is only a wrapper around a stateful session, so
you're only gaining convenience by using a Stateless one.
Why not write your own wrapper that allows for the execution of a rule flow
too?
Cheers,
Mike
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EM
Hi,
I don't think Drools supports this directly, but would this not be as
accomplishable with DSL?
Your Drools rule could then be written something like this (bare in mind I'm
no DSL expert):-
DSL:
[when]There is a hemoglobin lab result with=LabResult(type==hemoglobin)
[when]- a value less than
Without knowledge of your use case or domain model the below seems
reasonable!
Cheers,
Mike
_
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Lake Pancake
Sent: 30 May 2008 13:33
To: rules-users@lists.jboss.org
Subject: [rules-users] Re: Old drools-spring project
Tha
Partial answer.
2. Drools supports database interactions. Have a look at the "from" clause
which allows for retrieval of data from outside the working memory.
Cheers,
Mike
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Thalupula Ravi
Sent: 30 May 2008
Erm, Rule Flow springs immediately to mind.
Or you can use semaphore Facts yourself - but you're re-inventing the (Rule
Flow) wheel.
rule "rule 1"
when
condition is true
then
insert(new SemaphoreFact());
end
rule "rule 2"
when
SemaphoreFact()
So
for expressing my formulae - if that can be
achieved using a DSL.
Can the whole rule be defined in Groovy/Java - if so I might be easier doing
that. I have so much work to do!
many thanks
Richard
2008/5/2 Anstis, Michael (M.) <[EMAIL PROTECTED]>:
Hi Richard,
The "when" sec
Hi Richard,
The "when" section matches fact (object) patterns, so your requirement could
be written as:-
when there is a Test Fact 'A' and another Test Fact 'B' where "the 'x'
property of 'A'" equals "the 'y' property of fact 'B' plus 1" then.
This would become:-
rule "Rule 1"
when
It will occur whenever you (the developer) make it occur.
I guess Rulebase is the RETE network (without memory nodes) and the WM's are
in essence the RETE network memory nodes.
This is my interpretation of their roles.
Here's an example:-
Rulebase
RuleBase ruleBase = RuleBaseFactory.ne
Have you read the manual?
I would really, really suggest you do.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of anandhakrishnan
Sent: 28 April 2008 15:37
To: rules-users@lists.jboss.org
Subject: [rules-users] StateFullSession / StatelessSession
What
IMO, the analogy between Rule Engine and ORDBMS *could* be made with only
very simple business rules covering one object (presumably mapped to one
table). However you would still need to design mechanisms to support truth
maintenance and an activation schedule. Once the complexity of your business
hould work I think.
On Wed, Apr 23, 2008 at 5:50 PM, Anstis, Michael (M.) <[EMAIL PROTECTED]>
wrote:
So, in my usual helpful manner I thought Drools would be a perfect match and
put together what I thought would be a simple example:-
package com.sample
global com.sample.DBUtils dbut
I believe this is an example of backwards-chaining.
(From the manual) Drools only supports forward-chaining at present although
"...Drools will be adding support for Backward Chaining in its next major
release...".
Have you looked at Geoffrey De Smet's drools-solver excellent work? Will
this pr
So, in my usual helpful manner I thought Drools would be a perfect match and
put together what I thought would be a simple example:-
package com.sample
global com.sample.DBUtils dbutils;
rule "a1"
when
$max : Integer() from accumulate( Integer( $v : intValue ) from
dbutils.getNumbe
Don't ask me to explain why but the Drools team always recommend flattening
hierarchies before inserting into WM ;-)
I *think* this allows for individual facts' properties to be indexed in the
RETE network thus affording a performance increase.
I guess there's also implications to do with truth
I was inserting them more than once. But I don't see that happening.
In any event wouldn't the audit log tell me if I was doing that?
-A
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Anstis, Michael
(M.)
Sent: Thursday, April 17, 2008 2:11
I have tried to re-produce using "System.out.println" instead of IELogger
and I don't get any double activations :-(
Could the problem be elsewhere (e.g. IELogger?).
package com.sample
import com.sample.MyVariable;
rule "Light is off"
when
$brightness : MyVariable(uniqu
I *seem* to be able to still use "update" in the RHS with 4.0.5.
Perhaps I've got my binaries mixed up. If I get the chance I'll do a clean
install.
Thanks for the clarification - I don't want to end up confusing matters with
my "help" ;-)
-Original Message-
From: [EMAIL PROTECTED]
[mail
There is an implicit KnowledgeHelper object called "drools" available in the
RHS.
drools.getRule().getName() will provide what you need.
_
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: 11 April 2008 16:04
To: rules-users@lists.jboss.org
Subject
I am confident Drools supports what you are looking for; did you try
update() - or modify() - in the "then" part of the rule (and not in Java as
you code snippet)?
Can you explain more the need for the "computed" flag on the fact? Is the
value of a property set sometimes whilst calculated at othe
Do you need ruleflow? Perhaps this is too simple and I misunderstood.
package com.sample;
public class Test {
private Integer a;
private Integer b;
private Integer c;
public Integer getA() {
return a;
}
public Integer getB() {
return b;
}
I've got 4.0.5 and it mentions insert, update and retract throughout the
manual.
There was an API change some versions ago, but I forget when exactly.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of X10
Sent: 11 April 2008 12:34
To: Rules Users List
Subje
I was thinking something more like this:-
package com.sample
import com.sample.Test
rule "rule 1 - 1"
salience 90
when
a : Test(
computed == "false",
c < 15,
d >= 75)
then
System.out.println("setting e to 0");
a.setE(0);
In essence, yes. Have a look at "update" in the manual (and a read on Shadow
Facts will probably be useful too).
_
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jonathan
Guéhenneux
Sent: 11 April 2008 10:24
To: Rules Users List
Subject: RE: [rules-users] Synch Business O
1 - 100 of 286 matches
Mail list logo