Code example for Method

Methods: getName, invoke, setAccessible

0
		this.receiver = receiver;
		this.method = method;
	} 
	 
	public Object withParams(Object... params) {
		method.setAccessible(true);
		try { 
			return method.invoke(receiver, params);
		} catch(InvocationTargetException e) {
			throw new AndOrmException(MessageFormat.format(bundle.getString("invocation_failed"), method.getName(), e.getMessage()));
		} catch(IllegalAccessException ie) {
			throw new AndOrmException(MessageFormat.format(bundle.getString("invocation_failed"), method.getName(), ie.getMessage()));
		} 
	} 
	 
	public Object withoutParams() {
		return withParams(new Object[] {});
	} 
}