Stephen Kestle wrote:
I'm trying to make some fact templates in the form of
template "Address"
String line1
String line2
end
template "Person"
String name
int age
Address address
end
It complains that it is "Unable to resolve class "Address""
1. Is there any way around this -
FactTemplates are an experimental feature and only supports primitives
and strings as fields. It was based around using arrays for the models,
this made the implementation easy but tooling and integration with other
libraries being very hard. For 5.0 we using "type declarations" which
basically
I'm trying to make some fact templates in the form of
template "Address"
String line1
String line2
end
template "Person"
String name
int age
Address address
end
It complains that it is "Unable to resolve class "Address""
1. Is there any way around this - am I just getting synt
On Aug 11, 2008, at 9:30 AM, Ingomar Otter wrote:
>" Typically, a rulebase would be generated and cached on first use;
to save
>on the continually re-generation of the Rule Base; which is
expensive."
Read: Cache the rulebase (the rulebase object) with a Cache
mechanism of your choice.
Maybe this doesn't apply to your actual domain, but it seems to me
that you probably need some additional rules to decide what to do when
multiple conditions that affect the same values are encountered. By
analogy, when you're writing multithreaded code with a shared memory
model, you have to expli
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' )
Hello Harsh,
>The problem I am facing is that the salience specified in the drl is
not
>being used.
Please elaborate, this is a too general question. So the salience is
present in the generated drl?
Salience (by default) defines the execution order of those rules
which are activated (=
Hi Mike,
thanks for the reply.
Actually for each object I check, depending on how many rules are activated,
I'd need so many value holder too.
So, each value holder actually contains information about each activated
rule (e.g. regarding the temperature and detergent.
But thank you for the keyword
>" Typically, a rulebase would be generated and cached on first use;
to save
>on the continually re-generation of the Rule Base; which is
expensive."
Read: Cache the rulebase (the rulebase object) with a Cache
mechanism of your choice.
AFAIK there is no dedicated caching mechanism in Droo
Hi ,
i'm trying to implement caching of rules .
in the manual there is a statement as follows :
" Typically, a rulebase would be generated and cached on first use; to save
on the continually re-generation of the Rule Base; which is expensive."
how does rule base caches rules ? is there any
Hi ,
I am using Drools version 4.0.4.
I have created a dsl file for my drl ,I have set a salience for each rule .
The problem I am facing is that the salience specified in the drl is not
being used.
Now when I use the drl without the dsl . Things work just fine and the
salience is used .
What s
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
Hi,
I have the following problems:
I need to prove an object based on certain rules, where the parts of the
rules should be kept to be used in further process within my application.
In order to fetch those parts, my idea was to insert an additional object as
value holder for the rule's parts,
pu
Hi Jean-Baptiste,
Here is a good (complete) example you can try following:
http://www.redhatmagazine.com/2008/07/11/jboss-drools-meets-hibernate/
With kind regards,
Mike
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of BINET
JEAN-BA
Hi Matt,
thanks for the mind-opening idea ;-)
I'll try to remember this when I need to do such mapping again
Paul
Matt Geis wrote:
>
> You can do this. Keep in mind that the DSL engine will try to match each
> dsl mapping entry into the LHS of the rule, one by one, in the order they
> are de
On the contrary of what you said I read the documentation. And there is this
sentence :
"The next example shows how we can reason over the results of a hibernate
query. The Restaurant pattern will reason over and bind with each result in
turn:"
but after there is no example
I already tried
16 matches
Mail list logo