List<Method> list = classType.methodsByName( "onBreak" );
if ( list.size() == 0 ) {
throw new IllegalStateException( "MVELDebugHandler.onBreak cannot be found by JDI" );
}
Method method = list.get( 0 );
if (method != null && !method.isNative()) {
Location location = method.location();
if (location != null && location.codeIndex() != -1) {
req = getEventRequestManager().createBreakpointRequest(location);
req.addThreadFilter( ((ClassPrepareEvent) event).thread() );
req.setSuspendPolicy( EventRequest.SUSPEND_ALL );
} else {