@Test public void testStartProvidesHandle() { int act = cut.startRuntimeMeasurement(this, "testStartProvidesHandle-0"); assertEquals(0, act); act = cut.startRuntimeMeasurement(this, "testStartProvidesHandle-1"); assertEquals(1, act); }
@Override public int startRuntimeMeasurement(final Object instance, final String methodName) { final int handleId = runtimeInformation.size(); final RuntimeMeasurement measurement = new RuntimeMeasurement(); measurement.setTimeStarted(System.nanoTime()); measurement.setClassName(instance.getClass().getSimpleName()); measurement.setMethodName(methodName); runtimeInformation.add(measurement); return handleId; }
JPACoreDebugger implements JPAServiceDebugger { @Override public int startRuntimeMeasurement(final Object instance, final String methodName) { final int handleId = runtimeInformation.size(); final RuntimeMeasurement measurement = new RuntimeMeasurement(); measurement.setTimeStarted(System.nanoTime()); measurement.setClassName(instance.getClass().getSimpleName()); measurement.setMethodName(methodName); runtimeInformation.add(measurement); return handleId; } }
JPACoreDebugger implements JPAServiceDebugger { @Override public int startRuntimeMeasurement(final Object instance, final String methodName) { final int handleId = runtimeInformation.size(); final RuntimeMeasurement measurement = new RuntimeMeasurement(); measurement.setTimeStarted(System.nanoTime()); measurement.setClassName(instance.getClass().getSimpleName()); measurement.setMethodName(methodName); runtimeInformation.add(measurement); return handleId; }  }
JPACoreDebugger implements JPAServiceDebugger { @Override public int startRuntimeMeasurement(final Object instance, final String methodName) { final int handleId = runtimeInformation.size(); final RuntimeMeasurement measurement = new RuntimeMeasurement(); measurement.setTimeStarted(System.nanoTime()); measurement.setClassName(instance.getClass().getSimpleName()); measurement.setMethodName(methodName); runtimeInformation.add(measurement); return handleId; }  @Override int startRuntimeMeasurement(final Object instance, final String methodName); @Override void stopRuntimeMeasurement(final int handle); @Override Collection<RuntimeMeasurement> getRuntimeInformation(); }
JPACoreDebugger implements JPAServiceDebugger { @Override public int startRuntimeMeasurement(final Object instance, final String methodName) { final int handleId = runtimeInformation.size(); final RuntimeMeasurement measurement = new RuntimeMeasurement(); measurement.setTimeStarted(System.nanoTime()); measurement.setClassName(instance.getClass().getSimpleName()); measurement.setMethodName(methodName); runtimeInformation.add(measurement); return handleId; }  @Override int startRuntimeMeasurement(final Object instance, final String methodName); @Override void stopRuntimeMeasurement(final int handle); @Override Collection<RuntimeMeasurement> getRuntimeInformation();  }