@Override
    public List<BankDeposit> readXML(String xmlFilePath) throws XMLReaderDOMException {
        try {
            XMLValidator validator = new XMLValidator();
            validator.validateXML(xmlFilePath, DataPath.XSD_FILE);

            deposits = new ArrayList<>();
            DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();
            DocumentBuilder dBuilder = dbFactory.newDocumentBuilder();
            Document doc = dBuilder.parse(getClass().getResourceAsStream(xmlFilePath));
            NodeList nList = doc.getElementsByTagName(XMLTag.BANK);
            for (int i = 0; i < nList.getLength(); i++) {
                Node nNode = nList.item(i);
                BankDeposit deposit = new BankDeposit();
                if (nNode.getNodeType() == Node.ELEMENT_NODE) {
                    Element eElement = (Element) nNode;
                    deposit.setName(eElement.getElementsByTagName(XMLTag.NAME).item(0).getTextContent());
                    deposit.setCountry(eElement.getElementsByTagName(XMLTag.COUNTRY).item(0).getTextContent());
                    deposit.setType(DepositType.valueOf(eElement.getElementsByTagName(XMLTag.TYPE)
                            .item(0).getTextContent().toUpperCase()));
                    deposit.setDepositor(eElement.getElementsByTagName(XMLTag.DEPOSITOR).item(0).getTextContent());
                    deposit.setAccountId(eElement.getElementsByTagName(XMLTag.ACCOUNT_ID).item(0).getTextContent());
                    deposit.setAmount(Integer.parseInt(eElement.getElementsByTagName(XMLTag.AMOUNT).item(0).getTextContent()));
                    deposit.setProfitability(Integer.parseInt(eElement.getElementsByTagName(XMLTag.PROFITABILITY)
                            .item(0).getTextContent()));
                    deposit.setTimeConstraints(Integer.parseInt(eElement.getElementsByTagName(XMLTag.TIME_CONSTRAINTS)
                            .item(0).getTextContent()));
                }
                deposits.add(deposit);
            }
        } catch (ParserConfigurationException | SAXException | IOException ex) {
            throw new XMLReaderDOMException(ex);
        }

        return deposits;
    }