@Test public void testBasic() throws Exception { TestModel testModel = kieService.loadContent(Paths.convert(mainFilePath)); assertNotNull(testModel); assertMetadataRequestedForMainFile(); }
public T loadContent(Path path) { try { final org.uberfire.java.nio.file.Path ioPath = Paths.convert(path); if (pathResolver.isDotFile(ioPath)) { org.uberfire.java.nio.file.Path ioPrincipleFilePath = pathResolver.resolveMainFilePath(ioPath); if (!ioService.exists(ioPrincipleFilePath)) { ioPrincipleFilePath = ioPath; } final Path principleFilePath = Paths.convert(ioPrincipleFilePath); return constructContent(principleFilePath, overviewLoader.loadOverview(principleFilePath)); } else { return constructContent(path, overviewLoader.loadOverview(path)); } } catch (Exception e) { throw ExceptionUtilities.handleException(e); } }
KieService { public T loadContent(Path path) { try { final org.uberfire.java.nio.file.Path ioPath = Paths.convert(path); if (pathResolver.isDotFile(ioPath)) { org.uberfire.java.nio.file.Path ioPrincipleFilePath = pathResolver.resolveMainFilePath(ioPath); if (!ioService.exists(ioPrincipleFilePath)) { ioPrincipleFilePath = ioPath; } final Path principleFilePath = Paths.convert(ioPrincipleFilePath); return constructContent(principleFilePath, overviewLoader.loadOverview(principleFilePath)); } else { return constructContent(path, overviewLoader.loadOverview(path)); } } catch (Exception e) { throw ExceptionUtilities.handleException(e); } } }
KieService { public T loadContent(Path path) { try { final org.uberfire.java.nio.file.Path ioPath = Paths.convert(path); if (pathResolver.isDotFile(ioPath)) { org.uberfire.java.nio.file.Path ioPrincipleFilePath = pathResolver.resolveMainFilePath(ioPath); if (!ioService.exists(ioPrincipleFilePath)) { ioPrincipleFilePath = ioPath; } final Path principleFilePath = Paths.convert(ioPrincipleFilePath); return constructContent(principleFilePath, overviewLoader.loadOverview(principleFilePath)); } else { return constructContent(path, overviewLoader.loadOverview(path)); } } catch (Exception e) { throw ExceptionUtilities.handleException(e); } }  }
KieService { public T loadContent(Path path) { try { final org.uberfire.java.nio.file.Path ioPath = Paths.convert(path); if (pathResolver.isDotFile(ioPath)) { org.uberfire.java.nio.file.Path ioPrincipleFilePath = pathResolver.resolveMainFilePath(ioPath); if (!ioService.exists(ioPrincipleFilePath)) { ioPrincipleFilePath = ioPath; } final Path principleFilePath = Paths.convert(ioPrincipleFilePath); return constructContent(principleFilePath, overviewLoader.loadOverview(principleFilePath)); } else { return constructContent(path, overviewLoader.loadOverview(path)); } } catch (Exception e) { throw ExceptionUtilities.handleException(e); } }  T loadContent(Path path); String getSource(final Path path); }
KieService { public T loadContent(Path path) { try { final org.uberfire.java.nio.file.Path ioPath = Paths.convert(path); if (pathResolver.isDotFile(ioPath)) { org.uberfire.java.nio.file.Path ioPrincipleFilePath = pathResolver.resolveMainFilePath(ioPath); if (!ioService.exists(ioPrincipleFilePath)) { ioPrincipleFilePath = ioPath; } final Path principleFilePath = Paths.convert(ioPrincipleFilePath); return constructContent(principleFilePath, overviewLoader.loadOverview(principleFilePath)); } else { return constructContent(path, overviewLoader.loadOverview(path)); } } catch (Exception e) { throw ExceptionUtilities.handleException(e); } }  T loadContent(Path path); String getSource(final Path path);  }