A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://docs.pmd-code.org/latest/pmd_rules_xsl_codestyle.html below:

Code Style | PMD Source Code Analyzer

Rules which enforce a specific coding style.

Table of Contents UseConcatOnce

Since: PMD 5.0

Priority: Medium (3)

The XPath concat() functions accepts as many arguments as required so you can have "concat($a,’b’,$c)" rather than "concat($a,concat(‘b’,$c)".

This rule is defined by the following XPath expression:

//node()[contains(substring-after(@select,'concat'),'concat')]

Example(s):

<xsl:variable name="var" select="concat("Welcome",concat("to you ",$name))"/>
<xsl:variable name="var" select="concat("Welcome","to you ",$name))">

Use this rule by referencing it:

<rule ref="category/xsl/codestyle.xml/UseConcatOnce" />

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4