1 22 23 package org.aspectj.debugger.request; 24 25 import org.aspectj.debugger.base.*; 26 27 import com.sun.jdi.*; 28 import java.util.*; 29 30 38 39 public abstract class ClassesNeedingRequest extends Request { 40 41 private List classNames; 42 43 public ClassesNeedingRequest(Debugger debugger, List classNames) { 44 super(debugger); 45 this.classNames = classNames; 46 } 47 48 public List getReferenceTypes() throws NoVMException, DebuggerException { 49 List classes = new Vector(); 50 if (classNames == null || classNames.size() == 0) { 51 return classes; 52 } 53 Iterator iter = classNames.iterator(); 54 while (iter.hasNext()) { 55 String className = iter.next() + ""; 56 List refTypes = vm().classesByName(className); 57 if (refTypes.size() == 0) { 58 throw new InvalidClassException(className); 59 } 60 classes.addAll(refTypes); 61 } 62 return classes; 63 } 64 } 65 | Popular Tags |