/**
  * return true if passed intentionType has higher priority then one currently stored by this
  * visitor
  */
 public boolean hasHigherPriority(IntentionType intentionType) {
   return myIntentionType == null || myIntentionType.getPriority() < intentionType.getPriority();
 }
 private boolean visit(IntentionType intentionType) {
   if (hasHigherPriority(intentionType)) {
     myIntentionType = intentionType;
   }
   return myIntentionType.getPriority() > 0;
 }