I got solution!!!! Followed Toni Rikolla http://stackoverflow.com/questions/13572661/drools-guvnor-how-do-dates-and-times-work
rule "name"
when
DateRange($endDate: endDate !=null, isValidStructure($endDate.toString));
then
log.info("..........")
end
function Boolean isValidStructure (String date){
}
From: rules-users-bounces@lists.jboss.org [mailto:rules-users-bounces@lists.jboss.org]
On Behalf Of Gopu Shrestha
Sent: Thursday, March 13, 2014 10:54 AM
To: Rules Users List
Subject: [rules-users] compare date structure in WHEN part
I want to compare the date structure YYYY-MM-DD in when part. Can I do this?? any help will be appreciated..
rule "name"
when
DateRange($endDate: endDate !=null) // $endDate ==” YYYY-MM-DD” structure
then
log.info("..........")
end