public NSArray canidateRuleSetForRHSInContext(String rhs, D2WContext context) {
NSMutableSet canidateSet = new NSMutableSet();
for (Enumeration e = rules().objectEnumerator(); e.hasMoreElements();) {
Rule r = (Rule)e.nextElement();
if (r.rhsKeyPath().equals(rhs) && r.canFireInContext(context))
canidateSet.addObject(r);
}
return canidateSet.count() == 0 ? canidateSet.allObjects() :
EOSortOrdering.sortedArrayUsingKeyOrderArray(canidateSet.allObjects(), ruleSortOrderingKeyArray());
}