示例#1
0
 private void doExposePageLoadMethod(JavaClass jc) {
   boolean hitOne = false;
   for (Iterator itr = jc.findMethodsByName("Page_Load").iterator(); itr.hasNext(); ) {
     JavaMethod jm = (JavaMethod) itr.next();
     jm.addModifier(JavaKeywords.J_PUBLIC);
     hitOne = true;
   }
   if (!hitOne) {
     throw new RuntimeException(jc + " is a form class, but has no Page_Load method...");
   }
 }