Return-Path: X-Original-To: apmail-maven-commits-archive@www.apache.org Delivered-To: apmail-maven-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BDB0CE973 for ; Fri, 25 Jan 2013 22:00:01 +0000 (UTC) Received: (qmail 73866 invoked by uid 500); 25 Jan 2013 22:00:01 -0000 Delivered-To: apmail-maven-commits-archive@maven.apache.org Received: (qmail 73800 invoked by uid 500); 25 Jan 2013 22:00:01 -0000 Mailing-List: contact commits-help@maven.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@maven.apache.org Delivered-To: mailing list commits@maven.apache.org Received: (qmail 73792 invoked by uid 99); 25 Jan 2013 22:00:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 25 Jan 2013 22:00:01 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 25 Jan 2013 21:59:56 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 5F2032388C42 for ; Fri, 25 Jan 2013 21:58:41 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r847980 [22/23] - in /websites/production/maven/content/jxr: ./ apidocs/ apidocs/org/ apidocs/org/apache/ apidocs/org/apache/maven/ apidocs/org/apache/maven/jxr/ apidocs/org/apache/maven/jxr/ant/ apidocs/org/apache/maven/jxr/ant/class-use/ ... Date: Fri, 25 Jan 2013 21:58:32 -0000 To: commits@maven.apache.org From: olamy@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130125215841.5F2032388C42@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Added: websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReport.html ============================================================================== --- websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReport.html (added) +++ websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReport.html Fri Jan 25 21:58:29 2013 @@ -0,0 +1,194 @@ + + + + +JxrReport xref + + + +
+
+1   package org.apache.maven.plugin.jxr;
+2   
+3   /*
+4    * Licensed to the Apache Software Foundation (ASF) under one
+5    * or more contributor license agreements.  See the NOTICE file
+6    * distributed with this work for additional information
+7    * regarding copyright ownership.  The ASF licenses this file
+8    * to you under the Apache License, Version 2.0 (the
+9    * "License"); you may not use this file except in compliance
+10   * with the License.  You may obtain a copy of the License at
+11   *
+12   *   http://www.apache.org/licenses/LICENSE-2.0
+13   *
+14   * Unless required by applicable law or agreed to in writing,
+15   * software distributed under the License is distributed on an
+16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+17   * KIND, either express or implied.  See the License for the
+18   * specific language governing permissions and limitations
+19   * under the License.
+20   */
+21  
+22  import org.apache.maven.project.MavenProject;
+23  
+24  import java.io.File;
+25  import java.util.ArrayList;
+26  import java.util.Arrays;
+27  import java.util.List;
+28  import java.util.Locale;
+29  
+30  /**
+31   * Creates an html-based, cross referenced version of Java source code
+32   * for a project.
+33   *
+34   * @author <a href="mailto:bellingard.NO-SPAM@gmail.com">Fabrice Bellingard</a>
+35   * @version $Id: JxrReport.java 637378 2008-03-15 09:47:19Z bentmann $
+36   * @goal jxr
+37   */
+38  public class JxrReport
+39      extends AbstractJxrReport
+40  {
+41      /**
+42       * Source directories of the project.
+43       *
+44       * @parameter expression="${project.compileSourceRoots}"
+45       * @required
+46       * @readonly
+47       */
+48      private List sourceDirs;
+49  
+50      /**
+51       * Specifies the source path where the java files are located.
+52       * The paths are separated by '<code>;</code>'.
+53       *
+54       * @parameter expression="${sourcePath}"
+55       */
+56      private String sourcePath;
+57  
+58      /**
+59       * Folder where the Xref files will be copied to.
+60       *
+61       * @parameter expression="${project.reporting.outputDirectory}/xref"
+62       */
+63      private String destDir;
+64  
+65      /**
+66       * Folder where Javadoc is generated for this project.
+67       *
+68       * @parameter expression="${project.reporting.outputDirectory}/apidocs"
+69       */
+70      private File javadocDir;
+71  
+72      /**
+73       * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getDestinationDirectory()
+74       */
+75      protected String getDestinationDirectory()
+76      {
+77          return destDir;
+78      }
+79  
+80      /**
+81       * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getSourceRoots()
+82       */
+83      protected List getSourceRoots()
+84      {
+85          if ( sourcePath != null )
+86          {
+87              String[] sourcePathArray = sourcePath.split( ";" );
+88              if ( sourcePathArray.length > 0 )
+89              {
+90                  return Arrays.asList( sourcePathArray );
+91              }
+92          }
+93  
+94          List l = new ArrayList();
+95  
+96          if ( !"pom".equals( getProject().getPackaging().toLowerCase() ) )
+97          {
+98              l.addAll( sourceDirs );
+99          }
+100 
+101         if ( getProject().getExecutionProject() != null )
+102         {
+103             if ( !"pom".equals( getProject().getExecutionProject().getPackaging().toLowerCase() ) )
+104             {
+105                 l.addAll( getProject().getExecutionProject().getCompileSourceRoots() );
+106             }
+107         }
+108 
+109         return l;
+110     }
+111 
+112     /**
+113      * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getSourceRoots(org.apache.maven.project.MavenProject)
+114      */
+115     protected List getSourceRoots( MavenProject project )
+116     {
+117         List l = new ArrayList();
+118 
+119         if ( !"pom".equals( project.getPackaging().toLowerCase() ) )
+120         {
+121             l.addAll( project.getCompileSourceRoots() );
+122         }
+123 
+124         if ( project.getExecutionProject() != null )
+125         {
+126             if ( !"pom".equals( project.getExecutionProject().getPackaging().toLowerCase() ) )
+127             {
+128                 l.addAll( project.getExecutionProject().getCompileSourceRoots() );
+129             }
+130         }
+131 
+132         return l;
+133     }
+134 
+135     /**
+136      * @see org.apache.maven.reporting.MavenReport#getDescription(java.util.Locale)
+137      */
+138     public String getDescription( Locale locale )
+139     {
+140         return getBundle( locale ).getString( "report.xref.main.description" );
+141     }
+142 
+143     /**
+144      * @see org.apache.maven.reporting.MavenReport#getName(java.util.Locale)
+145      */
+146     public String getName( Locale locale )
+147     {
+148         return getBundle( locale ).getString( "report.xref.main.name" );
+149     }
+150 
+151     /**
+152      * @see org.apache.maven.reporting.MavenReport#getOutputName()
+153      */
+154     public String getOutputName()
+155     {
+156         return "xref/index";
+157     }
+158 
+159     /**
+160      * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getJavadocDir()
+161      */
+162     protected File getJavadocDir()
+163     {
+164         return javadocDir;
+165     }
+166 
+167     /**
+168      * @see org.apache.maven.reporting.AbstractMavenReport#setReportOutputDirectory(java.io.File)
+169      */
+170     public void setReportOutputDirectory( File reportOutputDirectory )
+171     {
+172         if ( ( reportOutputDirectory != null ) && ( !reportOutputDirectory.getAbsolutePath().endsWith( "xref" ) ) )
+173         {
+174             this.destDir = new File( reportOutputDirectory, "xref" ).getAbsolutePath();
+175         }
+176         else
+177         {
+178             this.destDir = reportOutputDirectory.getAbsolutePath();
+179         }
+180     }
+181 }
+
+
+ Added: websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReportUtil.html ============================================================================== --- websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReportUtil.html (added) +++ websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrReportUtil.html Fri Jan 25 21:58:29 2013 @@ -0,0 +1,337 @@ + + + + +JxrReportUtil xref + + + +
+
+1   package org.apache.maven.plugin.jxr;
+2   
+3   /*
+4    * Licensed to the Apache Software Foundation (ASF) under one
+5    * or more contributor license agreements.  See the NOTICE file
+6    * distributed with this work for additional information
+7    * regarding copyright ownership.  The ASF licenses this file
+8    * to you under the Apache License, Version 2.0 (the
+9    * "License"); you may not use this file except in compliance
+10   * with the License.  You may obtain a copy of the License at
+11   *
+12   *   http://www.apache.org/licenses/LICENSE-2.0
+13   *
+14   * Unless required by applicable law or agreed to in writing,
+15   * software distributed under the License is distributed on an
+16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+17   * KIND, either express or implied.  See the License for the
+18   * specific language governing permissions and limitations
+19   * under the License.
+20   */
+21  
+22  import java.io.IOException;
+23  import java.util.ArrayList;
+24  import java.util.Iterator;
+25  import java.util.List;
+26  
+27  import javax.xml.parsers.DocumentBuilderFactory;
+28  import javax.xml.parsers.FactoryConfigurationError;
+29  import javax.xml.parsers.ParserConfigurationException;
+30  import javax.xml.transform.TransformerException;
+31  
+32  import org.apache.maven.model.Plugin;
+33  import org.apache.maven.model.PluginExecution;
+34  import org.apache.maven.model.ReportPlugin;
+35  import org.apache.maven.model.Site;
+36  import org.apache.maven.project.MavenProject;
+37  import org.apache.maven.wagon.repository.Repository;
+38  import org.apache.xpath.XPathAPI;
+39  import org.apache.xpath.objects.XObject;
+40  import org.codehaus.plexus.util.StringInputStream;
+41  import org.codehaus.plexus.util.StringUtils;
+42  import org.codehaus.plexus.util.xml.Xpp3Dom;
+43  import org.w3c.dom.Document;
+44  import org.xml.sax.SAXException;
+45  
+46  /**
+47   * Utility class for the jxr report.
+48   *
+49   * @author <a href="mailto:vincent.siveton@gmail.com">Vincent Siveton</a>
+50   * @version $Id: JxrReportUtil.java 1145180 2011-07-11 14:02:55Z bimargulies $
+51   */
+52  public class JxrReportUtil
+53  {
+54      
+55      private static final String MAVEN_JAVADOC_PLUGIN_GROUP_ID = "org.apache.maven.plugins";
+56      private static final String MAVEN_JAVADOC_PLUGIN_ARTIFACT_ID = "maven-javadoc-plugin";
+57  
+58      /**
+59       * Determine if javadoc is aggregated in this project, paying attention to both
+60       * TODO: take cognizance of javadoc versus test-javadoc
+61       * the old parameter and the new mojo.
+62       * @param project
+63       * @return
+64       * @throws IOException
+65       */
+66      protected static boolean isJavadocAggregated( MavenProject project )
+67          throws IOException
+68      {
+69          // first check conf for obsolete aggregate param.
+70          boolean javadocAggregate = Boolean
+71                          .valueOf( JxrReportUtil.getMavenJavadocPluginBasicOption( project, "aggregate", "false" ) )
+72                          .booleanValue();
+73          if ( javadocAggregate ) 
+74          {
+75              return true;
+76          }
+77          List plugins = getMavenJavadocPlugins ( project );
+78          Iterator pi = plugins.iterator();
+79          while ( pi.hasNext() )
+80          {
+81              Object pluginObject = pi.next();
+82              
+83              if ( pluginObject instanceof Plugin )
+84              {
+85                  Plugin plugin = (Plugin)pluginObject;
+86                  List executions = plugin.getExecutions();
+87                  Iterator ei = executions.iterator();
+88                  while ( ei.hasNext() )
+89                  {
+90                      PluginExecution pe = (PluginExecution) ei.next();
+91                      List goals = pe.getGoals();
+92                      Iterator gi = goals.iterator();
+93                      while ( gi.hasNext() )
+94                      {
+95                          String goal = (String) gi.next();
+96                          if ( "aggregate".equals(goal) )
+97                          {
+98                              return true;
+99                          }
+100                     }
+101                 }
+102             } 
+103         }
+104         return false;
+105     }
+106     
+107     /**
+108      * Return the <code>optionName</code> value defined in a project for the "maven-javadoc-plugin" plugin.
+109      *
+110      * @param project not null
+111      * @param optionName the option name wanted
+112      * @param defaultValue a default value
+113      * @return the value for the option name or the default value. Could be null if not found.
+114      * @throws IOException if any
+115      */
+116     protected static String getMavenJavadocPluginBasicOption( MavenProject project, String optionName,
+117                                                               String defaultValue )
+118         throws IOException
+119     {
+120         List plugins = new ArrayList();
+121         for ( Iterator it = project.getModel().getReporting().getPlugins().iterator(); it.hasNext(); )
+122         {
+123             plugins.add( it.next() );
+124         }
+125         for ( Iterator it = project.getModel().getBuild().getPlugins().iterator(); it.hasNext(); )
+126         {
+127             plugins.add( it.next() );
+128         }
+129 
+130         String pluginArtifactId = MAVEN_JAVADOC_PLUGIN_ARTIFACT_ID;
+131         for ( Iterator it = plugins.iterator(); it.hasNext(); )
+132         {
+133             Object next = it.next();
+134 
+135             Xpp3Dom pluginConf = null;
+136 
+137             if ( next instanceof Plugin )
+138             {
+139                 Plugin plugin = (Plugin) next;
+140 
+141                 // using out-of-box Maven plugins
+142                 if ( !( ( plugin.getGroupId().equals( MAVEN_JAVADOC_PLUGIN_GROUP_ID ) ) && ( plugin.getArtifactId()
+143                     .equals( pluginArtifactId ) ) ) )
+144                 {
+145                     continue;
+146                 }
+147 
+148                 pluginConf = (Xpp3Dom) plugin.getConfiguration();
+149             }
+150 
+151             if ( next instanceof ReportPlugin )
+152             {
+153                 ReportPlugin reportPlugin = (ReportPlugin) next;
+154 
+155                 // using out-of-box Maven plugins
+156                 if ( !( ( reportPlugin.getGroupId().equals( MAVEN_JAVADOC_PLUGIN_GROUP_ID ) ) && ( reportPlugin
+157                     .getArtifactId().equals( pluginArtifactId ) ) ) )
+158                 {
+159                     continue;
+160                 }
+161 
+162                 pluginConf = (Xpp3Dom) reportPlugin.getConfiguration();
+163             }
+164 
+165             if ( pluginConf == null )
+166             {
+167                 continue;
+168             }
+169 
+170             try
+171             {
+172                 Document doc = DocumentBuilderFactory.newInstance().newDocumentBuilder()
+173                     .parse( new StringInputStream( pluginConf.toString() ) );
+174 
+175                 XObject obj = XPathAPI.eval( doc, "//configuration/" + optionName );
+176 
+177                 if ( StringUtils.isNotEmpty( obj.toString() ) )
+178                 {
+179                     return obj.toString();
+180                 }
+181             }
+182             catch ( SAXException e )
+183             {
+184                 throw new IOException( "SAXException: " + e.getMessage() );
+185             }
+186             catch ( ParserConfigurationException e )
+187             {
+188                 throw new IOException( "ParserConfigurationException: " + e.getMessage() );
+189             }
+190             catch ( FactoryConfigurationError e )
+191             {
+192                 throw new IOException( "FactoryConfigurationError: " + e.getMessage() );
+193             }
+194             catch ( TransformerException e )
+195             {
+196                 throw new IOException( "TransformerException: " + e.getMessage() );
+197             }
+198         }
+199 
+200         return defaultValue;
+201     }
+202     
+203     /**
+204      * Return the plugin references for the javadoc plugin in a project.
+205      *
+206      * @param project not null
+207      * @throws IOException if any
+208      */
+209     protected static List getMavenJavadocPlugins( MavenProject project )
+210         throws IOException
+211     {
+212         List plugins = new ArrayList();
+213         for ( Iterator it = project.getModel().getReporting().getPlugins().iterator(); it.hasNext(); )
+214         {
+215             plugins.add( it.next() );
+216         }
+217         for ( Iterator it = project.getModel().getBuild().getPlugins().iterator(); it.hasNext(); )
+218         {
+219             plugins.add( it.next() );
+220         }
+221         
+222         List result = new ArrayList();
+223 
+224         String pluginArtifactId = MAVEN_JAVADOC_PLUGIN_ARTIFACT_ID;
+225         for ( Iterator it = plugins.iterator(); it.hasNext(); )
+226         {
+227             Object next = it.next();
+228 
+229             if ( next instanceof Plugin )
+230             {
+231                 Plugin plugin = (Plugin) next;
+232 
+233                 // using out-of-box Maven plugins
+234                 if ( !( ( plugin.getGroupId().equals( MAVEN_JAVADOC_PLUGIN_GROUP_ID ) ) && ( plugin.getArtifactId()
+235                     .equals( pluginArtifactId ) ) ) )
+236                 {
+237                     continue;
+238                 }
+239 
+240                 result.add( plugin );
+241             }
+242 
+243             if ( next instanceof ReportPlugin )
+244             {
+245                 ReportPlugin reportPlugin = (ReportPlugin) next;
+246 
+247                 // using out-of-box Maven plugins
+248                 if ( !( ( reportPlugin.getGroupId().equals( MAVEN_JAVADOC_PLUGIN_GROUP_ID ) ) && ( reportPlugin
+249                     .getArtifactId().equals( pluginArtifactId ) ) ) )
+250                 {
+251                     continue;
+252                 }
+253                 result.add( reportPlugin );
+254             }
+255         }
+256         return result;
+257     }
+258 
+259     /**
+260      * Generates the site structure using the project hierarchy (project and its modules) or using the
+261      * distributionManagement elements from the pom.xml.
+262      *
+263      * @todo come from site plugin!
+264      * @see org.apache.maven.plugins.site.SiteStageMojo#getStructure( MavenProject project, boolean ignoreMissingSiteUrl )
+265      *
+266      * @param project
+267      * @param ignoreMissingSiteUrl
+268      * @return the structure relative path
+269      * @throws IOException if any
+270      */
+271     protected static String getStructure( MavenProject project, boolean ignoreMissingSiteUrl )
+272         throws IOException
+273     {
+274         if ( project.getDistributionManagement() == null )
+275         {
+276             String hierarchy = project.getName();
+277 
+278             MavenProject parent = project.getParent();
+279             while ( parent != null )
+280             {
+281                 hierarchy = parent.getName() + "/" + hierarchy;
+282                 parent = parent.getParent();
+283             }
+284 
+285             return hierarchy;
+286         }
+287 
+288         Site site = project.getDistributionManagement().getSite();
+289         if ( site == null )
+290         {
+291             if ( !ignoreMissingSiteUrl )
+292             {
+293                 throw new IOException(
+294                                        "Missing site information in the distribution management element in the project: '"
+295                                            + project.getName() + "'." );
+296             }
+297 
+298             return null;
+299         }
+300 
+301         if ( StringUtils.isEmpty( site.getUrl() ) )
+302         {
+303             if ( !ignoreMissingSiteUrl )
+304             {
+305                 throw new IOException( "The URL in the site is missing in the project descriptor." );
+306             }
+307 
+308             return null;
+309         }
+310 
+311         Repository repository = new Repository( site.getId(), site.getUrl() );
+312         if ( StringUtils.isEmpty( repository.getBasedir() ) )
+313         {
+314             return repository.getHost();
+315         }
+316 
+317         if ( repository.getBasedir().startsWith( "/" ) )
+318         {
+319             return repository.getHost() + repository.getBasedir();
+320         }
+321 
+322         return repository.getHost() + "/" + repository.getBasedir();
+323     }
+324 }
+
+
+ Added: websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrTestReport.html ============================================================================== --- websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrTestReport.html (added) +++ websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/JxrTestReport.html Fri Jan 25 21:58:29 2013 @@ -0,0 +1,172 @@ + + + + +JxrTestReport xref + + + +
+
+1   package org.apache.maven.plugin.jxr;
+2   
+3   /*
+4    * Licensed to the Apache Software Foundation (ASF) under one
+5    * or more contributor license agreements.  See the NOTICE file
+6    * distributed with this work for additional information
+7    * regarding copyright ownership.  The ASF licenses this file
+8    * to you under the Apache License, Version 2.0 (the
+9    * "License"); you may not use this file except in compliance
+10   * with the License.  You may obtain a copy of the License at
+11   *
+12   *   http://www.apache.org/licenses/LICENSE-2.0
+13   *
+14   * Unless required by applicable law or agreed to in writing,
+15   * software distributed under the License is distributed on an
+16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+17   * KIND, either express or implied.  See the License for the
+18   * specific language governing permissions and limitations
+19   * under the License.
+20   */
+21  
+22  import org.apache.maven.project.MavenProject;
+23  
+24  import java.io.File;
+25  import java.util.ArrayList;
+26  import java.util.List;
+27  import java.util.Locale;
+28  
+29  /**
+30   * Creates an html-based, cross referenced version of Java source code
+31   * for a project's test sources.
+32   *
+33   * @author <a href="mailto:bellingard.NO-SPAM@gmail.com">Fabrice Bellingard</a>
+34   * @author <a href="mailto:brett@apache.org">Brett Porter</a>
+35   * @version $Id: JxrTestReport.java 1145180 2011-07-11 14:02:55Z bimargulies $
+36   * @goal test-jxr
+37   */
+38  public class JxrTestReport
+39      extends AbstractJxrReport
+40  {
+41      /**
+42       * Test directories of the project.
+43       *
+44       * @parameter expression="${project.testCompileSourceRoots}"
+45       * @required
+46       * @readonly
+47       */
+48      private List sourceDirs;
+49  
+50      /**
+51       * Folder where the Xref files will be copied to.
+52       *
+53       * @parameter expression="${project.reporting.outputDirectory}/xref-test"
+54       */
+55      private String destDir;
+56  
+57      /**
+58       * Folder where Test Javadoc is generated for this project.
+59       *
+60       * @parameter expression="${project.reporting.outputDirectory}/testapidocs"
+61       */
+62      private File testJavadocDir;
+63  
+64      /**
+65       * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getSourceRoots()
+66       */
+67      protected List getSourceRoots()
+68      {
+69          List l = new ArrayList();
+70  
+71          if ( !"pom".equals( getProject().getPackaging().toLowerCase() ) )
+72          {
+73              l.addAll( sourceDirs );
+74          }
+75  
+76          if ( getProject().getExecutionProject() != null )
+77          {
+78              if ( !"pom".equals( getProject().getExecutionProject().getPackaging().toLowerCase() ) )
+79              {
+80                  l.addAll( getProject().getExecutionProject().getTestCompileSourceRoots() );
+81              }
+82          }
+83  
+84          return l;
+85      }
+86  
+87      /**
+88       * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getSourceRoots(org.apache.maven.project.MavenProject)
+89       */
+90      protected List getSourceRoots( MavenProject project )
+91      {
+92          List l = new ArrayList();
+93  
+94          if ( project.getExecutionProject() != null )
+95          {
+96              if ( !"pom".equals( project.getExecutionProject().getPackaging().toLowerCase() ) )
+97              {
+98                  l.addAll( project.getExecutionProject().getTestCompileSourceRoots() );
+99              }
+100         }
+101 
+102         return l;
+103     }
+104 
+105     /**
+106      * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getDestinationDirectory()
+107      */
+108     protected String getDestinationDirectory()
+109     {
+110         return destDir;
+111     }
+112 
+113     /**
+114      * @see org.apache.maven.reporting.MavenReport#getDescription(java.util.Locale)
+115      */
+116     public String getDescription( Locale locale )
+117     {
+118         return getBundle( locale ).getString( "report.xref.test.description" );
+119     }
+120 
+121     /**
+122      * @see org.apache.maven.reporting.MavenReport#getName(java.util.Locale)
+123      */
+124     public String getName( Locale locale )
+125     {
+126         return getBundle( locale ).getString( "report.xref.test.name" );
+127     }
+128 
+129     /**
+130      * @see org.apache.maven.reporting.MavenReport#getOutputName()
+131      */
+132     public String getOutputName()
+133     {
+134         return "xref-test/index";
+135     }
+136 
+137     /**
+138      * @see org.apache.maven.plugin.jxr.AbstractJxrReport#getJavadocDir()
+139      */
+140     protected File getJavadocDir()
+141     {
+142         return testJavadocDir;
+143     }
+144 
+145     /**
+146      * @see org.apache.maven.reporting.AbstractMavenReport#setReportOutputDirectory(java.io.File)
+147      */
+148     public void setReportOutputDirectory( File reportOutputDirectory )
+149     {
+150         if ( ( reportOutputDirectory != null ) && ( !reportOutputDirectory.getAbsolutePath().endsWith( "xref-test" ) ) )
+151         {
+152             this.destDir = new File( reportOutputDirectory, "xref-test" ).getAbsolutePath();
+153         }
+154         else
+155         {
+156             this.destDir = reportOutputDirectory.getAbsolutePath();
+157         }
+158     }
+159 }
+
+
+ Added: websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/PluginLogAdapter.html ============================================================================== --- websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/PluginLogAdapter.html (added) +++ websites/production/maven/content/jxr/xref/org/apache/maven/plugin/jxr/PluginLogAdapter.html Fri Jan 25 21:58:29 2013 @@ -0,0 +1,89 @@ + + + + +PluginLogAdapter xref + + + +
+
+1   package org.apache.maven.plugin.jxr;
+2   
+3   /*
+4    * Licensed to the Apache Software Foundation (ASF) under one
+5    * or more contributor license agreements.  See the NOTICE file
+6    * distributed with this work for additional information
+7    * regarding copyright ownership.  The ASF licenses this file
+8    * to you under the Apache License, Version 2.0 (the
+9    * "License"); you may not use this file except in compliance
+10   * with the License.  You may obtain a copy of the License at
+11   *
+12   *   http://www.apache.org/licenses/LICENSE-2.0
+13   *
+14   * Unless required by applicable law or agreed to in writing,
+15   * software distributed under the License is distributed on an
+16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+17   * KIND, either express or implied.  See the License for the
+18   * specific language governing permissions and limitations
+19   * under the License.
+20   */
+21  
+22  import org.apache.maven.plugin.logging.Log;
+23  
+24  /**
+25   * Logging adapter.
+26   *
+27   * @author <a href="mailto:brett.NO-SPAM@apache.org">Brett Porter</a>
+28   * @version $Id: PluginLogAdapter.java 637378 2008-03-15 09:47:19Z bentmann $
+29   */
+30  public class PluginLogAdapter
+31      implements org.apache.maven.jxr.log.Log
+32  {
+33      private final Log log;
+34  
+35      /**
+36       * Class constructor
+37       *
+38       * @param log   the Log object to be used
+39       */
+40      public PluginLogAdapter( Log log )
+41      {
+42          this.log = log;
+43      }
+44  
+45      /**
+46       * @see org.apache.maven.jxr.log.Log#info(String)
+47       */
+48      public void info( String string )
+49      {
+50          log.info( string );
+51      }
+52  
+53      /**
+54       * @see org.apache.maven.jxr.log.Log#debug(String)
+55       */
+56      public void debug( String string )
+57      {
+58          log.debug( string );
+59      }
+60  
+61      /**
+62       * @see org.apache.maven.jxr.log.Log#warn(String)
+63       */
+64      public void warn( String string )
+65      {
+66          log.warn( string );
+67      }
+68  
+69      /**
+70       * @see org.apache.maven.jxr.log.Log#error(String)  
+71       */
+72      public void error( String string )
+73      {
+74          log.error( string );
+75      }
+76  }
+
+
+