1 16 package org.apache.commons.attributes; 17 18 import java.util.Iterator ; 19 import java.util.List ; 20 21 25 public class CircularDependencyError extends RepositoryError { 26 27 37 public CircularDependencyError (String className, List dependencyList) { 38 super (className + ":" + listDeps (dependencyList), null); 39 } 40 41 46 private static String listDeps (List dependencyList) { 47 StringBuffer sb = new StringBuffer (); 48 Iterator iter = dependencyList.iterator (); 49 while (iter.hasNext ()) { 50 sb.append (iter.next ()); 51 if (iter.hasNext ()) { 52 sb.append (" -> "); 53 } 54 } 55 56 return sb.toString (); 57 } 58 } | Popular Tags |