コード例 #1
0
ファイル: TypeFacadeQueries.java プロジェクト: yllyx/sakai
 /**
  * This method constructs a HashMap (Long typeId, TypeFacade typeFacade) with the items in
  * typeList
  *
  * @param typeList
  * @return a HashMap
  */
 private HashMap createTypeFacadeMapById(List typeList) {
   HashMap typeFacadeMap = new HashMap();
   for (int i = 0; i < typeList.size(); i++) {
     TypeD typeData = (TypeD) typeList.get(i);
     TypeFacade typeFacade = new TypeFacade(typeData);
     typeFacadeMap.put(typeData.getTypeId(), typeFacade);
   }
   return typeFacadeMap;
 }
コード例 #2
0
ファイル: TypeFacadeQueries.java プロジェクト: yllyx/sakai
 public List getFacadeListByAuthorityDomain(String authority, String domain) {
   ArrayList typeList = new ArrayList();
   List list = getListByAuthorityDomain(authority, domain);
   for (int i = 0; i < list.size(); i++) {
     TypeD type = (TypeD) list.get(i);
     TypeFacade f =
         new TypeFacade(
             type.getAuthority(), type.getDomain(), type.getKeyword(), type.getDescription());
     f.setTypeId(type.getTypeId());
     typeList.add(f);
   }
   return (List) typeList;
 }