diff --git a/schemas/iso19139/src/main/plugin/iso19139/extract-relations.xsl b/schemas/iso19139/src/main/plugin/iso19139/extract-relations.xsl index 6d5099e171a..96a6bf0c0cc 100644 --- a/schemas/iso19139/src/main/plugin/iso19139/extract-relations.xsl +++ b/schemas/iso19139/src/main/plugin/iso19139/extract-relations.xsl @@ -33,7 +33,7 @@ xmlns:gco="http://www.isotc211.org/2005/gco" xmlns:gmx="http://www.isotc211.org/2005/gmx" xmlns:xlink="http://www.w3.org/1999/xlink" - xmlns:util="java:org.fao.geonet.util.XslUtil" + xmlns:digestUtils="java:org.apache.commons.codec.digest.DigestUtils" xmlns:exslt="http://exslt.org/common" xmlns:gn-fn-rel="http://geonetwork-opensource.org/xsl/functions/relations" version="2.0" @@ -109,7 +109,7 @@ - + - + <xsl:apply-templates mode="get-iso19139-localized-string" diff --git a/schemas/iso19139/src/main/plugin/iso19139/index-fields/index.xsl b/schemas/iso19139/src/main/plugin/iso19139/index-fields/index.xsl index e885ed65eef..93c5038a705 100644 --- a/schemas/iso19139/src/main/plugin/iso19139/index-fields/index.xsl +++ b/schemas/iso19139/src/main/plugin/iso19139/index-fields/index.xsl @@ -33,7 +33,7 @@ xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:gn-fn-index="http://geonetwork-opensource.org/xsl/functions/index" xmlns:index="java:org.fao.geonet.kernel.search.EsSearchManager" - xmlns:util="java:org.fao.geonet.util.XslUtil" + xmlns:digestUtils="java:org.apache.commons.codec.digest.DigestUtils" xmlns:exslt="http://exslt.org/common" xmlns:date-util="java:org.fao.geonet.utils.DateUtil" xmlns:daobs="http://daobs.org" @@ -1106,7 +1106,7 @@ <atomfeed><xsl:value-of select="gmd:linkage/gmd:URL"/></atomfeed> </xsl:if> <link type="object">{ - "hash": "<xsl:value-of select="util:md5HexIgnoreWhiteSpaces(string(exslt:node-set(.)))"/>", + "hash": "<xsl:value-of select="digestUtils:md5Hex(string(exslt:node-set(normalize-space(.))))"/>", "idx": <xsl:value-of select="position()"/>, "protocol":"<xsl:value-of select="util:escapeForJson((gmd:protocol/*/text())[1])"/>", "mimeType":"<xsl:value-of select="if (*/gmx:MimeFileType) diff --git a/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-add.xsl b/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-add.xsl index 2463f327f97..ddf0ad7bc50 100644 --- a/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-add.xsl +++ b/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-add.xsl @@ -36,7 +36,7 @@ Note: It assumes that it will be adding new items in xmlns:gmx="http://www.isotc211.org/2005/gmx" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" - xmlns:util="java:org.fao.geonet.util.XslUtil" + xmlns:digestUtils="java:org.apache.commons.codec.digest.DigestUtils" xmlns:exslt="http://exslt.org/common" exclude-result-prefixes="#all" version="2.0"> @@ -193,7 +193,7 @@ Note: It assumes that it will be adding new items in gmd:CI_OnlineResource/gmd:linkage/gmd:URL, gmd:CI_OnlineResource/gmd:protocol/*, gmd:CI_OnlineResource/gmd:name/gco:CharacterString))) - and ($resourceHash = '' or util:md5HexIgnoreWhiteSpaces(string(exslt:node-set(.))) = $resourceHash)]" + and ($resourceHash = '' or digestUtils:md5Hex(string(exslt:node-set(normalize-space(.)))) = $resourceHash)]" priority="2"> <xsl:call-template name="createOnlineSrc"/> </xsl:template> diff --git a/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-remove.xsl b/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-remove.xsl index e91d90e3fe6..66ce59c5310 100644 --- a/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-remove.xsl +++ b/schemas/iso19139/src/main/plugin/iso19139/process/onlinesrc-remove.xsl @@ -29,7 +29,7 @@ Stylesheet used to remove a reference to a online resource. xmlns:gco="http://www.isotc211.org/2005/gco" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" - xmlns:util="java:org.fao.geonet.util.XslUtil" + xmlns:digestUtils="java:org.apache.commons.codec.digest.DigestUtils" xmlns:exslt="http://exslt.org/common" exclude-result-prefixes="#all" version="2.0"> @@ -59,7 +59,7 @@ Stylesheet used to remove a reference to a online resource. or normalize-space(gmd:CI_OnlineResource/gmd:linkage/gmd:URL) = $url and count(gmd:CI_OnlineResource/gmd:name/gmd:PT_FreeText/gmd:textGroup[gmd:LocalisedCharacterString = $name]) > 0 or normalize-space(gmd:CI_OnlineResource/gmd:linkage/gmd:URL) = $url and normalize-space(gmd:CI_OnlineResource/gmd:protocol/*) = 'WWW:DOWNLOAD-1.0-http--download')) ) - and ($resourceHash = '' or util:md5HexIgnoreWhiteSpaces(string(exslt:node-set(.))) = $resourceHash)]" + and ($resourceHash = '' or digestUtils:md5Hex(string(exslt:node-set(normalize-space(.)))) = $resourceHash)]" priority="2"/> <!-- Do a copy of every node and attribute -->