public void loadRepositoryFromGeneXML(String geneXML) {
        if (geneXML == null || geneXML.equals(""))
            return;
        try {

            //System.out.println(geneXML);

            Document document = builder.parse(new InputSource(new StringReader(geneXML)));

            //  genome
            NodeList genomelist = document.getElementsByTagName("genome");
            for (int i = 0; i < genomelist.getLength(); i++) {
                Node genomeElement = genomelist.item(i);
                NamedNodeMap genomeAttributes = genomeElement.getAttributes();
                String organismGroupId = getNodeStringValue(genomeAttributes.getNamedItem("organismgroupid"));
                String numberofchromosomesString = getNodeStringValue(genomeAttributes.getNamedItem("numberofchromosomes"));
                int numberofchromosomes = Integer.parseInt(numberofchromosomesString);

                repository.genomeTable.insertNewGenome(organismGroupId, numberofchromosomes);

                NodeList chromosomeElements = genomeElement.getChildNodes();
                for (int j = 0; j < chromosomeElements.getLength(); j++) {
                    Node chromosomeElement = chromosomeElements.item(j);

                    //  genome/chromosome
                    if (chromosomeElement.getNodeName().equals("chromosome")) {
                        loadChromosomeToGenomeFromXMLNode(organismGroupId, chromosomeElement);
                    }
                }

            }

        } catch (SAXException sxe) {
            // Error generated during parsing
            Exception x = sxe;
            if (sxe.getException() != null)
                x = sxe.getException();
            //x.printStackTrace();

        } catch (IOException ioe) {
            // I/O error
            //ioe.printStackTrace();
        }
    }