From 3b76cffce61af9f00b3c61c7337e92931ef03d13 Mon Sep 17 00:00:00 2001 From: "harald.bratko" Date: Fri, 2 Sep 2005 16:05:35 +0000 Subject: Added an "AnyNumber" to IdentificationNumber to be able to use numbers not yet defined within the person data schema. git-svn-id: https://joinup.ec.europa.eu/svn/moa-idspss/trunk@492 d688527b-c9ab-4aba-bd8d-4036d912da1d --- .../at/gv/egovernment/moa/id/config/ConfigurationBuilder.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'id.server/src/at') diff --git a/id.server/src/at/gv/egovernment/moa/id/config/ConfigurationBuilder.java b/id.server/src/at/gv/egovernment/moa/id/config/ConfigurationBuilder.java index c399b72b7..7059aa3fa 100644 --- a/id.server/src/at/gv/egovernment/moa/id/config/ConfigurationBuilder.java +++ b/id.server/src/at/gv/egovernment/moa/id/config/ConfigurationBuilder.java @@ -763,7 +763,7 @@ public class ConfigurationBuilder { *

e.g.:
* input element: *
- * <pr:Firmenbuchnummer shortForm="FN">000468 i</pr:Firmenbuchnummer> + * <pr:Firmenbuchnummer Identifier="FN">000468 i</pr:Firmenbuchnummer> *

* return value: urn:publicid:gv.at+wbpk+FN468i * @@ -776,9 +776,10 @@ public class ConfigurationBuilder { return null; } String identificationNumber = number.getFirstChild().getNodeValue(); + String identifier = number.getAttribute("Identifier"); // remove all blanks identificationNumber = StringUtils.removeBlanks(identificationNumber); - if (number.getLocalName().equals("Firmenbuchnummer")) { + if (number.getLocalName().equals("Firmenbuchnummer") || identifier.equalsIgnoreCase("fn")) { // delete zeros from the beginning of the number identificationNumber = StringUtils.deleteLeadingZeros(identificationNumber); // remove hyphens @@ -786,9 +787,8 @@ public class ConfigurationBuilder { } StringBuffer identityLinkDomainIdentifier = new StringBuffer(Constants.URN_PREFIX_WBPK); identityLinkDomainIdentifier.append("+"); - String shortForm = number.getAttribute("ShortForm"); - if (!identificationNumber.startsWith(shortForm)) { - identityLinkDomainIdentifier.append(shortForm); + if (!identificationNumber.startsWith(identifier)) { + identityLinkDomainIdentifier.append(identifier); } identityLinkDomainIdentifier.append("+"); identityLinkDomainIdentifier.append(identificationNumber); -- cgit v1.2.3