added getAllRules