/** * This method checks if all indications contained within the {@code indications} are VALID. * * @param indications {@code List} of {@code XmlDom} containing the INDICATION * @return {@code true} if all contained indications are equal to VALID, otherwise {@code false} */ private boolean areAllIndicationsValid(final List<XmlDom> indications) { boolean valid = indications.size() > 0; for (final XmlDom indicationDom : indications) { final String indication = indicationDom.getText(); valid = valid && Indication.VALID.equals(indication); } return valid; }
/** * This method returns the {@code List} of {@code String} id based on the given XPath query and * set of optional parameters. * * @param xPath XPath query * @param parameters array of {@code String }parameters * @return {@code List} of id */ private List<String> getIdList(final String xPath, final String... parameters) { final List<String> idList = new ArrayList<String>(); final List<XmlDom> elements = getElements(xPath, parameters); for (final XmlDom element : elements) { final String id = element.getAttribute("Id"); idList.add(id); } return idList; }