The jdk setting is independent for each plugin, so you have to tell the PMD
plugin that you are using JDK 1.5 in your code.

regards,

Wim

2006/2/9, javed mandary <[EMAIL PROTECTED]>:
>
> Hi all,
>          am currently having a problem when running site with m2.0.2  , I
> have configured PMD in reporting tag:
>
> ------------- POM extract------------------
>             <plugin>
>                 <groupId>org.apache.maven.plugins</groupId>
>                 <artifactId>maven-pmd-plugin</artifactId>
>                 <configuration>
>                     <rulesets>
>                         <ruleset>/rulesets/basic.xml</ruleset>
>                         <ruleset>/rulesets/controversial.xml</ruleset>
>                     </rulesets>
>                     <format>xml</format>
>                     <linkXref>true</linkXref>
>                     <sourceEncoding>utf-8</sourceEncoding>
>                     <minimumTokens>100</minimumTokens>
>                 </configuration>
>             </plugin>
> ----------------------------------------------------
>
> Am using JDK 1.5 however but in a certain class I have used "enum" and PMD
> is not very happy about that and throws an exception:
>
>
> -----------------Extract console -----------------------------------------
> [INFO] Error during report generation
>
> Embedded error: Failure executing PMD for:
> C:\devtools\mvnwork\FILES\9feb\c
>
> ore\presentation\reffapp-web-core-presentation-web\src\main\java\com\Answer.java
> ERROR: Can't use enum as a keyword in pre-JDK 1.5 target
>
> ----------------------------------------------------------------------------------------------------------------
>
> Is there any workaround such as my site generation continues , with PMD
> just
> ignoring  "enum" ?
>
> kind regards,
>          Javed
>
>

Reply via email to