@Test public void testLoadProjectFromPath() { final WorkspaceController wc = new WorkspaceController(); }
public void loadProjectFromPath(final String path) throws IOException { final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); final DocumentBuilder builder; final Document doc; try { builder = factory.newDocumentBuilder(); doc = builder.parse(new File(path)); final Element projectRoot = doc.getDocumentElement(); workspace.loadWorkspaceFrom(projectRoot, langDefRoot); workspaceLoaded = true; } catch (ParserConfigurationException e) { throw new RuntimeException(e); } catch (SAXException e) { throw new RuntimeException(e); } }
WorkspaceController { public void loadProjectFromPath(final String path) throws IOException { final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); final DocumentBuilder builder; final Document doc; try { builder = factory.newDocumentBuilder(); doc = builder.parse(new File(path)); final Element projectRoot = doc.getDocumentElement(); workspace.loadWorkspaceFrom(projectRoot, langDefRoot); workspaceLoaded = true; } catch (ParserConfigurationException e) { throw new RuntimeException(e); } catch (SAXException e) { throw new RuntimeException(e); } } }
WorkspaceController { public void loadProjectFromPath(final String path) throws IOException { final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); final DocumentBuilder builder; final Document doc; try { builder = factory.newDocumentBuilder(); doc = builder.parse(new File(path)); final Element projectRoot = doc.getDocumentElement(); workspace.loadWorkspaceFrom(projectRoot, langDefRoot); workspaceLoaded = true; } catch (ParserConfigurationException e) { throw new RuntimeException(e); } catch (SAXException e) { throw new RuntimeException(e); } } WorkspaceController(); }
WorkspaceController { public void loadProjectFromPath(final String path) throws IOException { final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); final DocumentBuilder builder; final Document doc; try { builder = factory.newDocumentBuilder(); doc = builder.parse(new File(path)); final Element projectRoot = doc.getDocumentElement(); workspace.loadWorkspaceFrom(projectRoot, langDefRoot); workspaceLoaded = true; } catch (ParserConfigurationException e) { throw new RuntimeException(e); } catch (SAXException e) { throw new RuntimeException(e); } } WorkspaceController(); Workspace getWorkspace(); void setLangDefDtd(InputStream is); void setLangResourceBundle(ResourceBundle bundle); void setStyleList(List<String[]> list); void setLangDefFilePath(final String filePath); void setLangDefStream(InputStream in); void loadBlockLanguage(final Element root); void resetLanguage(); String getSaveString(); Node getSaveNode(); Node getSaveNode(final boolean validate); void loadFreshWorkspace(); void loadProjectFromPath(final String path); void loadProjectFromElement(Element elementToLoad); void loadProject(String projectContents, String langDefContents); void resetWorkspace(); JComponent getWorkspacePanel(); void setSelectedFile(File selectedFile); JComponent getSearchBar(); Iterable<SearchableContainer> getAllSearchableContainers(); static void main(final String[] args); }
WorkspaceController { public void loadProjectFromPath(final String path) throws IOException { final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setNamespaceAware(true); final DocumentBuilder builder; final Document doc; try { builder = factory.newDocumentBuilder(); doc = builder.parse(new File(path)); final Element projectRoot = doc.getDocumentElement(); workspace.loadWorkspaceFrom(projectRoot, langDefRoot); workspaceLoaded = true; } catch (ParserConfigurationException e) { throw new RuntimeException(e); } catch (SAXException e) { throw new RuntimeException(e); } } WorkspaceController(); Workspace getWorkspace(); void setLangDefDtd(InputStream is); void setLangResourceBundle(ResourceBundle bundle); void setStyleList(List<String[]> list); void setLangDefFilePath(final String filePath); void setLangDefStream(InputStream in); void loadBlockLanguage(final Element root); void resetLanguage(); String getSaveString(); Node getSaveNode(); Node getSaveNode(final boolean validate); void loadFreshWorkspace(); void loadProjectFromPath(final String path); void loadProjectFromElement(Element elementToLoad); void loadProject(String projectContents, String langDefContents); void resetWorkspace(); JComponent getWorkspacePanel(); void setSelectedFile(File selectedFile); JComponent getSearchBar(); Iterable<SearchableContainer> getAllSearchableContainers(); static void main(final String[] args);  }