/** * Invoke the default constructor * * @return The constructed instance * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object newInstance() throws InvocationTargetException { return this.newInstance( this.getIndex( EMPTY_CLASS_ARRAY ), null ); }
/** * Invoke a parameterized constructor * * @param parameterTypes The parameter types * @param args The parameter arguments to pass along * * @return The constructed instance * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object newInstance( Class[] parameterTypes, Object[] args) throws InvocationTargetException { return this.newInstance( this.getIndex( parameterTypes ), args ); }
/** * Access to invoke a method on the class that this fast class handles * * @param name The name of the method to invoke, * @param parameterTypes The method parameter types * @param obj The instance on which to invoke the method * @param args The parameter arguments * * @return The method result * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object invoke( String name, Class[] parameterTypes, Object obj, Object[] args) throws InvocationTargetException { return this.invoke( this.getIndex( name, parameterTypes ), obj, args ); }
public Object newInstance( Class[] parameterTypes, Object[] args) throws InvocationTargetException { return this.newInstance( this.getIndex( parameterTypes ), args ); }
public Object newInstance( Class[] parameterTypes, Object[] args) throws InvocationTargetException { return this.newInstance( this.getIndex( parameterTypes ), args ); }
/** * Invoke the default constructor * * @return The constructed instance * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object newInstance() throws InvocationTargetException { return this.newInstance( this.getIndex( EMPTY_CLASS_ARRAY ), null ); }
public Object newInstance() throws InvocationTargetException { return this.newInstance( this.getIndex( EMPTY_CLASS_ARRAY ), null ); }
public Object newInstance() throws InvocationTargetException { return this.newInstance( this.getIndex( EMPTY_CLASS_ARRAY ), null ); }
public Object invoke( int index, Object obj, Object[] args) throws InvocationTargetException { Method[] methods = this.type.getMethods(); try { return methods[index].invoke( obj, args ); } catch ( ArrayIndexOutOfBoundsException e ) { throw new IllegalArgumentException( "Cannot find matching method/constructor" ); } catch ( IllegalAccessException e ) { throw new InvocationTargetException( e ); } }
/** * Invoke a parameterized constructor * * @param parameterTypes The parameter types * @param args The parameter arguments to pass along * * @return The constructed instance * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object newInstance( Class[] parameterTypes, Object[] args) throws InvocationTargetException { return this.newInstance( this.getIndex( parameterTypes ), args ); }
public Object invoke( int index, Object obj, Object[] args) throws InvocationTargetException { Method[] methods = this.type.getMethods(); try { return methods[index].invoke( obj, args ); } catch ( ArrayIndexOutOfBoundsException e ) { throw new IllegalArgumentException( "Cannot find matching method/constructor" ); } catch ( IllegalAccessException e ) { throw new InvocationTargetException( e ); } }
/** * Access to invoke a method on the class that this fast class handles * * @param name The name of the method to invoke, * @param parameterTypes The method parameter types * @param obj The instance on which to invoke the method * @param args The parameter arguments * * @return The method result * * @throws InvocationTargetException Indicates a problem performing invocation */ public Object invoke( String name, Class[] parameterTypes, Object obj, Object[] args) throws InvocationTargetException { return this.invoke( this.getIndex( name, parameterTypes ), obj, args ); }