CPD Results

The following document contains the results of PMD's CPD 4.2.5.

Duplications

File Line
dk/sosi/seal/modelbuilders/IDCardModelBuilder.java 141
dk/sosi/seal/modelbuilders/IDCardModelBuilder.java 189
                } else if (IDValues.USER_LOG.equals(attributeValue)) {
                    // Iterate saml:Attributes in UserLog
                    NodeList samlAttributeNodes = ((Element) attributeStatementNodeList.item(nodeCount)).getElementsByTagNameNS(NameSpaces.SAML2ASSERTION_SCHEMA, SAMLTags.ATTRIBUTE);

                    for (int samlAttributeCount = 0; samlAttributeCount < samlAttributeNodes.getLength(); samlAttributeCount++) {
                        Element samlAttribute = (Element) samlAttributeNodes.item(samlAttributeCount);
                        String attributeName = samlAttribute.getAttributes().getNamedItem(SAMLAttributes.NAME).getNodeValue();
                        Element elmAttributeValue =  (Element) samlAttribute.getElementsByTagNameNS(NameSpaces.SAML2ASSERTION_SCHEMA, SAMLTags.ATTRIBUTE_VALUE).item(0);
                        String attributeNameValue = XmlUtil.getTextNodeValue(elmAttributeValue);

                        if (MedcomAttributes.USER_CIVIL_REGISTRATION_NUMBER.equals(attributeName)) {
File Line
dk/sosi/seal/modelbuilders/IDCardModelBuilder.java 141
dk/sosi/seal/modelbuilders/IDCardModelBuilder.java 160
                } else if (IDValues.IDCARD_DATA.equals(attributeValue)) {
                    // Iterate saml:Attributes in IDCard
                    NodeList samlAttributeNodes = ((Element) attributeStatementNodeList.item(nodeCount)).getElementsByTagNameNS(NameSpaces.SAML2ASSERTION_SCHEMA, SAMLTags.ATTRIBUTE);

                    for (int samlAttributeCount = 0; samlAttributeCount < samlAttributeNodes.getLength(); samlAttributeCount++) {
                        Element samlAttribute = (Element) samlAttributeNodes.item(samlAttributeCount);
                        String attributeName = samlAttribute.getAttributes().getNamedItem(SAMLAttributes.NAME).getNodeValue();
                        Element elmAttributeValue =  (Element) samlAttribute.getElementsByTagNameNS(NameSpaces.SAML2ASSERTION_SCHEMA, SAMLTags.ATTRIBUTE_VALUE).item(0);
                        String attributeNameValue = XmlUtil.getTextNodeValue(elmAttributeValue);
                        // Cert Hash
                        if (SOSIAttributes.OCES_CERT_HASH.equals(attributeName)) {