Added new code as part of the conversion from XML based rules to Groovy based scripts