@Test(expected = RuntimeException.class) public void testBuildDetector_invalidParams() { val factory = new ConstantThresholdDetectorFactoryProvider(); val document = readDocument("constant-threshold-invalid-params"); factory.buildDetector(document); }
@Override public ConstantThresholdDetector buildDetector(DetectorDocument document) { notNull(document, "document can't be null"); val params = parseParams(document); return new ConstantThresholdDetector(document.getUuid(), params, document.isTrusted()); }
ConstantThresholdDetectorFactoryProvider implements DetectorFactoryProvider<ConstantThresholdDetector> { @Override public ConstantThresholdDetector buildDetector(DetectorDocument document) { notNull(document, "document can't be null"); val params = parseParams(document); return new ConstantThresholdDetector(document.getUuid(), params, document.isTrusted()); } }
ConstantThresholdDetectorFactoryProvider implements DetectorFactoryProvider<ConstantThresholdDetector> { @Override public ConstantThresholdDetector buildDetector(DetectorDocument document) { notNull(document, "document can't be null"); val params = parseParams(document); return new ConstantThresholdDetector(document.getUuid(), params, document.isTrusted()); }  }
ConstantThresholdDetectorFactoryProvider implements DetectorFactoryProvider<ConstantThresholdDetector> { @Override public ConstantThresholdDetector buildDetector(DetectorDocument document) { notNull(document, "document can't be null"); val params = parseParams(document); return new ConstantThresholdDetector(document.getUuid(), params, document.isTrusted()); }  @Override ConstantThresholdDetector buildDetector(DetectorDocument document); }
ConstantThresholdDetectorFactoryProvider implements DetectorFactoryProvider<ConstantThresholdDetector> { @Override public ConstantThresholdDetector buildDetector(DetectorDocument document) { notNull(document, "document can't be null"); val params = parseParams(document); return new ConstantThresholdDetector(document.getUuid(), params, document.isTrusted()); }  @Override ConstantThresholdDetector buildDetector(DetectorDocument document);  }