Пример #1
0
 public boolean containEnum(String name) {
   Iterator<ABSEnum> i = setOfEnum.iterator();
   while (i.hasNext()) {
     ABSEnum ai = i.next();
     if (name.equals(ai.getName())) {
       return true;
     }
   }
   return false;
 }
Пример #2
0
  public ABSEnum getEnum(String name) {

    Iterator<ABSEnum> i = setOfEnum.iterator();
    while (i.hasNext()) {
      ABSEnum ai = i.next();
      // System.out.println(ai.getName()+"jshdf");
      if (name.equals(ai.getName())) {

        return ai;
      }
    }
    return null;
  }