private void init() throws IOException { // Make sure its there if (scormSettingsHandler.getManifestFile().exists()) { try { _navViewer = new NavigationViewer(scormSettingsHandler); } catch (IOException e) { throw e; } catch (JDOMParseException e) { throw new IOException("Parse exception", e); } catch (Exception ex) { throw new OLATRuntimeException(ScormManager.class, "Could not load manifest", ex); } // Package Links - use a clone so we can add referenced elements Element manifestRoot = (Element) _navViewer.getRootElement().clone(); // now get the organizations node Element orgs = manifestRoot.getChild(CP_Core.ORGANIZATIONS, manifestRoot.getNamespace()); Element[] tmp = _navViewer.getOrganizationList(); organizationElements = new LinkedList(); for (int i = 0; i < tmp.length; ++i) { organizationElements.add(tmp[i]); } // remember the default organization _defaultorg = _navViewer.getDefaultOrgElement(orgs); // NO orgs, so cant play - flag it if (_defaultorg == null) { _ReloadNoItemFoundExceptionFlag = false; } else { _sequence = new SequenceManager( _defaultorg.getAttributeValue(CP_Core.IDENTIFIER), scormSettingsHandler); // it exists so try to load it... try { initialize(); } catch (Exception ex) { _error_found = true; throw new OLATRuntimeException(ScormManager.class, "Could not initialise manifest", ex); } } // } else { // problems if we cannot find the nav file... _error_found = true; } }