public static Map<String, Product> getListOfProducts() {

		try {
			builder = factory.newDocumentBuilder();

			File propertiesFile = new File("src/com/woolfer/testtask/properties/PriceOfProducts.xml");

			try {
				Document doc = builder.parse(propertiesFile);
				Element root = doc.getDocumentElement();
				NodeList itemOfProducts = root.getChildNodes();

				listOfProducts = new HashMap<String, Product>();
				for (int i = 0; i < itemOfProducts.getLength(); i++) {
					Node elementListOfProducts = itemOfProducts.item(i);

					if (elementListOfProducts instanceof Element) {
						Element element = (Element) elementListOfProducts;
						String code = element.getTagName();
						String price = NameOfProductProperties.PRICE.toString().toLowerCase();
						String nwp = NameOfProductProperties.NUMBEROFWHOLESALEPRODUCTS.toString().toLowerCase();
						String wholesalePrice = NameOfProductProperties.WHOLESALEPRICE.toString().toLowerCase();
						product = new Product(code);
						if (element.hasAttribute(price))
							product.setPrice(Double.parseDouble(element.getAttribute(price)));
						if (element.hasAttribute(nwp))
							product.setNumberOfWholesaleProducts(Integer.parseInt(element.getAttribute(nwp)));
						if (element.hasAttribute(wholesalePrice))
							product.setWholesalePrise(Double.parseDouble(element.getAttribute(wholesalePrice)));
						listOfProducts.put(code, product);
					}
				}

			} catch (SAXException e) {
				e.printStackTrace();
			} catch (IOException e) {
				e.printStackTrace();
			}
		} catch (ParserConfigurationException e1) {
			e1.printStackTrace();
		}
		return listOfProducts;
	}