1 54 package org.logicalcobwebs.cglib.reflect; 55 56 import java.lang.reflect.Constructor ; 57 import java.lang.reflect.InvocationTargetException ; 58 59 public class FastConstructor extends FastMember 60 { 61 FastConstructor(FastClass fc, Constructor constructor) { 62 super(fc, constructor, fc.getIndex(constructor.getParameterTypes())); 63 } 64 65 public Class [] getParameterTypes() { 66 return ((Constructor )member).getParameterTypes(); 67 } 68 69 public Class [] getExceptionTypes() { 70 return ((Constructor )member).getExceptionTypes(); 71 } 72 73 public Object newInstance() throws InvocationTargetException { 74 return fc.newInstance(index, null); 75 } 76 77 public Object newInstance(Object [] args) throws InvocationTargetException { 78 return fc.newInstance(index, args); 79 } 80 81 public Constructor getJavaConstructor() { 82 return (Constructor )member; 83 } 84 } 85 | Popular Tags |