@Test public void testGetPMMLURI() { final Path modelPath = mock(Path.class); final String dmnModel = "model.dmn"; final String path = "default: final BiConsumer<String, String> assertPMMLURI = (expected, pmmlFileName) -> { assertEquals(expected, domainValidator.getPMMLURI(modelPath, pmmlFileName).toString()); }; when(modelPath.getFileName()).thenReturn(dmnModel); when(modelPath.toURI()).thenReturn(path + dmnModel); assertPMMLURI.accept("default: assertPMMLURI.accept("default: assertPMMLURI.accept("default: }
URI getPMMLURI(final Path modelPath, final String pmmlRelativeURI) { return URI .create(modelPath.toURI()) .resolve(pmmlRelativeURI); }
DMNDomainValidatorImpl implements DMNDomainValidator { URI getPMMLURI(final Path modelPath, final String pmmlRelativeURI) { return URI .create(modelPath.toURI()) .resolve(pmmlRelativeURI); } }
DMNDomainValidatorImpl implements DMNDomainValidator { URI getPMMLURI(final Path modelPath, final String pmmlRelativeURI) { return URI .create(modelPath.toURI()) .resolve(pmmlRelativeURI); } @Inject  DMNDomainValidatorImpl(final DMNMarshallerStandalone dmnMarshaller,
                                  final DMNDiagramUtils dmnDiagramUtils,
                                  final DMNMarshallerImportsHelperStandalone importsHelper,
                                  final DMNIOHelper dmnIOHelper); }
DMNDomainValidatorImpl implements DMNDomainValidator { URI getPMMLURI(final Path modelPath, final String pmmlRelativeURI) { return URI .create(modelPath.toURI()) .resolve(pmmlRelativeURI); } @Inject  DMNDomainValidatorImpl(final DMNMarshallerStandalone dmnMarshaller,
                                  final DMNDiagramUtils dmnDiagramUtils,
                                  final DMNMarshallerImportsHelperStandalone importsHelper,
                                  final DMNIOHelper dmnIOHelper); @PostConstruct void setupValidator(); @Override String getDefinitionSetId(); @Override @SuppressWarnings("unchecked") void validate(final Diagram diagram,
                         final Consumer<Collection<DomainViolation>> resultConsumer); @Override Collection<DomainViolation> validate(final Diagram diagram,
                                                final String diagramXml); }
DMNDomainValidatorImpl implements DMNDomainValidator { URI getPMMLURI(final Path modelPath, final String pmmlRelativeURI) { return URI .create(modelPath.toURI()) .resolve(pmmlRelativeURI); } @Inject  DMNDomainValidatorImpl(final DMNMarshallerStandalone dmnMarshaller,
                                  final DMNDiagramUtils dmnDiagramUtils,
                                  final DMNMarshallerImportsHelperStandalone importsHelper,
                                  final DMNIOHelper dmnIOHelper); @PostConstruct void setupValidator(); @Override String getDefinitionSetId(); @Override @SuppressWarnings("unchecked") void validate(final Diagram diagram,
                         final Consumer<Collection<DomainViolation>> resultConsumer); @Override Collection<DomainViolation> validate(final Diagram diagram,
                                                final String diagramXml);  }