ClassUtility.callMethod(method, getWaveReady(), parameterValues.toArray());
} catch (final CoreException e) {
LOGGER.error(WAVE_DISPATCH_ERROR, e);
// Propagate the wave exception
throw new WaveException(wave, e);
}
} else {
// If no custom method was proviced, call the default method named 'processWave(wave)'
try {
ClassUtility.getMethodByName(getWaveReady().getClass(), AbstractWaveReady.PROCESS_WAVE_METHOD_NAME).invoke(getWaveReady(), wave);
} catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException e) {
LOGGER.error(WAVE_DISPATCH_ERROR, e);
// Propagate the wave exception
throw new WaveException(wave, e);
}
}
}