I thought about adding that, but I feel like we would just be reimplementing java, in this case. So, if you need anything else other than simple java beans, you should implement it as a java class.<div><br></div><div>    Regarding the constructor, I might still add a constructor that receives all fields as parameters, just to reduce verbosity when using the java dialect, but if you are using mvel dialect, you can use &quot;with&quot;:</div>
<div><br></div><div>rule ...</div><div>when ...</div><div>then</div><div>    with( person = new Person() ) {</div><div>         name = &quot;Bob&quot;,</div><div>         age = 35</div><div>    }</div><div>    insert( person );</div>
<div>end</div><div>  </div><div>    Edson</div><div><div><br><div class="gmail_quote">2010/8/9 Tina Vießmann <span dir="ltr">&lt;<a href="mailto:tviessmann@stud.hs-bremen.de">tviessmann@stud.hs-bremen.de</a>&gt;</span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi,<br>
<br>
is it possible to define a function/constructor inside a fact type<br>
declaration? If yes, how can it be done?<br>
<br>
Thank you :)<br>
Tina<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>  Edson Tirelli<br>  JBoss Drools Core Development<br>  JBoss by Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a><br>
</div></div>