コード例 #1
0
 public static ClassFilter[] readFilters(List children) throws InvalidDataException {
   if (children == null || children.size() == 0) {
     return ClassFilter.EMPTY_ARRAY;
   }
   List<ClassFilter> classFiltersList = new ArrayList<ClassFilter>(children.size());
   for (Iterator i = children.iterator(); i.hasNext(); ) {
     final ClassFilter classFilter = new ClassFilter();
     classFilter.readExternal((Element) i.next());
     classFiltersList.add(classFilter);
   }
   return classFiltersList.toArray(new ClassFilter[classFiltersList.size()]);
 }
コード例 #2
0
 public static ClassFilter create(Element element) throws InvalidDataException {
   ClassFilter filter = new ClassFilter();
   filter.readExternal(element);
   return filter;
 }