Hi all.
Is it possible to get mailet-parameters from a Matcher, I wrote a matcher and a mailet:
(assembly.xml)
<mailet match="IsCustomer" class="DoStuff">
<connection>jdbc:mysql:///whatever</connection>
<username>user</username>
<password>something</password>
<query>select domain from customer</query>
</mailet>
(What I want to do is to get the Matcher conditions from a db.)
DoStuff.java (mailet) has no problems getting connection, username, etc.
I want to access the parameters from my matcher as well.
getMatcherConfig().getMailetContext().getAttribute("connection"); doesn't do the job
unless somebody sets the attribute first, I guess.
Is there any way around this, i.e. other than passing the parameters in the matcher
condition part (well, it does the job but it's ugly):
<mailet match="IsCustomer=jdbc:mysql:///whatever,user,something,select domain from
customer" class="DoStuff">
</mailet>
Regards,
Rauno