You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Dennis Lundberg <de...@apache.org> on 2010/07/01 23:33:52 UTC
Re: svn commit: r959435 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Now that we are starting to use Java 5 code, we should probably document
somewhere on the site that this component requires Java 5.
There is a prerequisite for Maven 2.2.1 in the POM, but for shared
components that info doesn't show up anywhere on the generated site.
On 2010-06-30 23:13, hboutemy@apache.org wrote:
> Author: hboutemy
> Date: Wed Jun 30 21:13:06 2010
> New Revision: 959435
>
> URL: http://svn.apache.org/viewvc?rev=959435&view=rev
> Log:
> use StringBuilder instead of String +=
>
> Modified:
> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
>
> Modified: maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
> URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=959435&r1=959434&r2=959435&view=diff
> ==============================================================================
> --- maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java (original)
> +++ maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java Wed Jun 30 21:13:06 2010
> @@ -356,43 +356,43 @@ public class DefaultSiteTool
> toTokeniser.nextToken();
> }
>
> - String relativePath = "";
> + StringBuilder relativePath = new StringBuilder();
>
> // add back refs for the rest of from location.
> while ( fromTokeniser.hasMoreTokens() )
> {
> fromTokeniser.nextToken();
>
> - relativePath += "..";
> + relativePath.append( ".." );
>
> if ( fromTokeniser.hasMoreTokens() )
> {
> - relativePath += File.separatorChar;
> + relativePath.append( File.separatorChar );
> }
> }
>
> if ( relativePath.length() != 0 && toTokeniser.hasMoreTokens() )
> {
> - relativePath += File.separatorChar;
> + relativePath.append( File.separatorChar );
> }
>
> // add fwd fills for whatever's left of to.
> while ( toTokeniser.hasMoreTokens() )
> {
> - relativePath += toTokeniser.nextToken();
> + relativePath.append( toTokeniser.nextToken() );
>
> if ( toTokeniser.hasMoreTokens() )
> {
> - relativePath += File.separatorChar;
> + relativePath.append( File.separatorChar );
> }
> }
>
> - if ( !relativePath.equals( to ) )
> + if ( getLogger().isDebugEnabled() && !relativePath.equals( to ) )
> {
> getLogger().debug( "Mapped url: " + to + " to relative path: " + relativePath );
> }
>
> - return relativePath;
> + return relativePath.toString();
> }
>
> /** {@inheritDoc} */
>
>
>
--
Dennis Lundberg
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: svn commit: r959435 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Posted by Stephen Connolly <st...@gmail.com>.
On 2 July 2010 22:45, Hervé BOUTEMY <he...@free.fr> wrote:
> Le vendredi 02 juillet 2010, Dennis Lundberg a écrit :
> > I had another look at Niall's patch. My original objection was that the
> > value of the JVM that ran the build (or really the site generation) was
> > output in the report. I think we should just remove that part and only
> > focus on the "source" and "target" values of the maven-compiler-plugin
> > configuration.
> +1 I had the same feeling when reading the patch today :)
>
>
Well since toolchains is released, the JVM that's running Maven is really
irrelevant in deciding what JVM is required for a plugin
> >
> > On 2010-07-02 18:15, Hervé BOUTEMY wrote:
> > > good point.
> > >
> > > we have MPIR-80 that should exactly document this, but the proposed
> > > implementation wasn't accepted.
> > > Time to try to implement this feature, IMHO
> > >
> > > Le jeudi 01 juillet 2010, Dennis Lundberg a écrit :
> > >> Now that we are starting to use Java 5 code, we should probably
> document
> > >> somewhere on the site that this component requires Java 5.
> > >>
> > >> There is a prerequisite for Maven 2.2.1 in the POM, but for shared
> > >> components that info doesn't show up anywhere on the generated site.
> > >>
> > >> On 2010-06-30 23:13, hboutemy@apache.org wrote:
> > >>> Author: hboutemy
> > >>> Date: Wed Jun 30 21:13:06 2010
> > >>> New Revision: 959435
> > >>>
> > >>> URL: http://svn.apache.org/viewvc?rev=959435&view=rev
> > >>> Log:
> > >>> use StringBuilder instead of String +=
> > >>>
> > >>> Modified:
> > >>>
> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven
> > >>> /d oxia/tools/DefaultSiteTool.java
> > >>>
> > >>> Modified:
> > >>>
> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> > >>> i a/tools/DefaultSiteTool.java URL:
> > >>>
> http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/m
> > >>> a
> > >>>
> in/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=959435&r
> > >>> 1=9 59434&r2=959435&view=diff
> > >>>
> =======================================================================
> > >>> = ====== ---
> > >>>
> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> > >>> i a/tools/DefaultSiteTool.java (original) +++
> > >>>
> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> > >>> i a/tools/DefaultSiteTool.java Wed Jun 30 21:13:06 2010 @@ -356,43
> > >>> +356,43 @@ public class DefaultSiteTool
> > >>>
> > >>> toTokeniser.nextToken();
> > >>>
> > >>> }
> > >>>
> > >>> - String relativePath = "";
> > >>> + StringBuilder relativePath = new StringBuilder();
> > >>>
> > >>> // add back refs for the rest of from location.
> > >>> while ( fromTokeniser.hasMoreTokens() )
> > >>> {
> > >>>
> > >>> fromTokeniser.nextToken();
> > >>>
> > >>> - relativePath += "..";
> > >>> + relativePath.append( ".." );
> > >>>
> > >>> if ( fromTokeniser.hasMoreTokens() )
> > >>> {
> > >>>
> > >>> - relativePath += File.separatorChar;
> > >>> + relativePath.append( File.separatorChar );
> > >>>
> > >>> }
> > >>>
> > >>> }
> > >>>
> > >>> if ( relativePath.length() != 0 &&
> toTokeniser.hasMoreTokens()
> > >>> ) {
> > >>>
> > >>> - relativePath += File.separatorChar;
> > >>> + relativePath.append( File.separatorChar );
> > >>>
> > >>> }
> > >>>
> > >>> // add fwd fills for whatever's left of to.
> > >>> while ( toTokeniser.hasMoreTokens() )
> > >>> {
> > >>>
> > >>> - relativePath += toTokeniser.nextToken();
> > >>> + relativePath.append( toTokeniser.nextToken() );
> > >>>
> > >>> if ( toTokeniser.hasMoreTokens() )
> > >>> {
> > >>>
> > >>> - relativePath += File.separatorChar;
> > >>> + relativePath.append( File.separatorChar );
> > >>>
> > >>> }
> > >>>
> > >>> }
> > >>>
> > >>> - if ( !relativePath.equals( to ) )
> > >>> + if ( getLogger().isDebugEnabled() && !relativePath.equals(
> to
> > >>> ) )
> > >>>
> > >>> {
> > >>>
> > >>> getLogger().debug( "Mapped url: " + to + " to relative
> > >>> path: " + relativePath );
> > >>>
> > >>> }
> > >>>
> > >>> - return relativePath;
> > >>> + return relativePath.toString();
> > >>>
> > >>> }
> > >>>
> > >>> /** {@inheritDoc} */
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: dev-help@maven.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: svn commit: r959435 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Posted by Hervé BOUTEMY <he...@free.fr>.
Le vendredi 02 juillet 2010, Dennis Lundberg a écrit :
> I had another look at Niall's patch. My original objection was that the
> value of the JVM that ran the build (or really the site generation) was
> output in the report. I think we should just remove that part and only
> focus on the "source" and "target" values of the maven-compiler-plugin
> configuration.
+1 I had the same feeling when reading the patch today :)
>
> On 2010-07-02 18:15, Hervé BOUTEMY wrote:
> > good point.
> >
> > we have MPIR-80 that should exactly document this, but the proposed
> > implementation wasn't accepted.
> > Time to try to implement this feature, IMHO
> >
> > Le jeudi 01 juillet 2010, Dennis Lundberg a écrit :
> >> Now that we are starting to use Java 5 code, we should probably document
> >> somewhere on the site that this component requires Java 5.
> >>
> >> There is a prerequisite for Maven 2.2.1 in the POM, but for shared
> >> components that info doesn't show up anywhere on the generated site.
> >>
> >> On 2010-06-30 23:13, hboutemy@apache.org wrote:
> >>> Author: hboutemy
> >>> Date: Wed Jun 30 21:13:06 2010
> >>> New Revision: 959435
> >>>
> >>> URL: http://svn.apache.org/viewvc?rev=959435&view=rev
> >>> Log:
> >>> use StringBuilder instead of String +=
> >>>
> >>> Modified:
> >>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven
> >>> /d oxia/tools/DefaultSiteTool.java
> >>>
> >>> Modified:
> >>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> >>> i a/tools/DefaultSiteTool.java URL:
> >>> http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/m
> >>> a
> >>> in/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=959435&r
> >>> 1=9 59434&r2=959435&view=diff
> >>> =======================================================================
> >>> = ====== ---
> >>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> >>> i a/tools/DefaultSiteTool.java (original) +++
> >>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/dox
> >>> i a/tools/DefaultSiteTool.java Wed Jun 30 21:13:06 2010 @@ -356,43
> >>> +356,43 @@ public class DefaultSiteTool
> >>>
> >>> toTokeniser.nextToken();
> >>>
> >>> }
> >>>
> >>> - String relativePath = "";
> >>> + StringBuilder relativePath = new StringBuilder();
> >>>
> >>> // add back refs for the rest of from location.
> >>> while ( fromTokeniser.hasMoreTokens() )
> >>> {
> >>>
> >>> fromTokeniser.nextToken();
> >>>
> >>> - relativePath += "..";
> >>> + relativePath.append( ".." );
> >>>
> >>> if ( fromTokeniser.hasMoreTokens() )
> >>> {
> >>>
> >>> - relativePath += File.separatorChar;
> >>> + relativePath.append( File.separatorChar );
> >>>
> >>> }
> >>>
> >>> }
> >>>
> >>> if ( relativePath.length() != 0 && toTokeniser.hasMoreTokens()
> >>> ) {
> >>>
> >>> - relativePath += File.separatorChar;
> >>> + relativePath.append( File.separatorChar );
> >>>
> >>> }
> >>>
> >>> // add fwd fills for whatever's left of to.
> >>> while ( toTokeniser.hasMoreTokens() )
> >>> {
> >>>
> >>> - relativePath += toTokeniser.nextToken();
> >>> + relativePath.append( toTokeniser.nextToken() );
> >>>
> >>> if ( toTokeniser.hasMoreTokens() )
> >>> {
> >>>
> >>> - relativePath += File.separatorChar;
> >>> + relativePath.append( File.separatorChar );
> >>>
> >>> }
> >>>
> >>> }
> >>>
> >>> - if ( !relativePath.equals( to ) )
> >>> + if ( getLogger().isDebugEnabled() && !relativePath.equals( to
> >>> ) )
> >>>
> >>> {
> >>>
> >>> getLogger().debug( "Mapped url: " + to + " to relative
> >>> path: " + relativePath );
> >>>
> >>> }
> >>>
> >>> - return relativePath;
> >>> + return relativePath.toString();
> >>>
> >>> }
> >>>
> >>> /** {@inheritDoc} */
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: svn commit: r959435 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Posted by Dennis Lundberg <de...@apache.org>.
I had another look at Niall's patch. My original objection was that the
value of the JVM that ran the build (or really the site generation) was
output in the report. I think we should just remove that part and only
focus on the "source" and "target" values of the maven-compiler-plugin
configuration.
On 2010-07-02 18:15, Hervé BOUTEMY wrote:
> good point.
>
> we have MPIR-80 that should exactly document this, but the proposed
> implementation wasn't accepted.
> Time to try to implement this feature, IMHO
>
> Le jeudi 01 juillet 2010, Dennis Lundberg a écrit :
>> Now that we are starting to use Java 5 code, we should probably document
>> somewhere on the site that this component requires Java 5.
>>
>> There is a prerequisite for Maven 2.2.1 in the POM, but for shared
>> components that info doesn't show up anywhere on the generated site.
>>
>> On 2010-06-30 23:13, hboutemy@apache.org wrote:
>>> Author: hboutemy
>>> Date: Wed Jun 30 21:13:06 2010
>>> New Revision: 959435
>>>
>>> URL: http://svn.apache.org/viewvc?rev=959435&view=rev
>>> Log:
>>> use StringBuilder instead of String +=
>>>
>>> Modified:
>>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/d
>>> oxia/tools/DefaultSiteTool.java
>>>
>>> Modified:
>>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
>>> a/tools/DefaultSiteTool.java URL:
>>> http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/ma
>>> in/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=959435&r1=9
>>> 59434&r2=959435&view=diff
>>> ========================================================================
>>> ====== ---
>>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
>>> a/tools/DefaultSiteTool.java (original) +++
>>> maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
>>> a/tools/DefaultSiteTool.java Wed Jun 30 21:13:06 2010 @@ -356,43 +356,43
>>> @@ public class DefaultSiteTool
>>>
>>> toTokeniser.nextToken();
>>>
>>> }
>>>
>>> - String relativePath = "";
>>> + StringBuilder relativePath = new StringBuilder();
>>>
>>> // add back refs for the rest of from location.
>>> while ( fromTokeniser.hasMoreTokens() )
>>> {
>>>
>>> fromTokeniser.nextToken();
>>>
>>> - relativePath += "..";
>>> + relativePath.append( ".." );
>>>
>>> if ( fromTokeniser.hasMoreTokens() )
>>> {
>>>
>>> - relativePath += File.separatorChar;
>>> + relativePath.append( File.separatorChar );
>>>
>>> }
>>>
>>> }
>>>
>>> if ( relativePath.length() != 0 && toTokeniser.hasMoreTokens() )
>>> {
>>>
>>> - relativePath += File.separatorChar;
>>> + relativePath.append( File.separatorChar );
>>>
>>> }
>>>
>>> // add fwd fills for whatever's left of to.
>>> while ( toTokeniser.hasMoreTokens() )
>>> {
>>>
>>> - relativePath += toTokeniser.nextToken();
>>> + relativePath.append( toTokeniser.nextToken() );
>>>
>>> if ( toTokeniser.hasMoreTokens() )
>>> {
>>>
>>> - relativePath += File.separatorChar;
>>> + relativePath.append( File.separatorChar );
>>>
>>> }
>>>
>>> }
>>>
>>> - if ( !relativePath.equals( to ) )
>>> + if ( getLogger().isDebugEnabled() && !relativePath.equals( to )
>>> )
>>>
>>> {
>>>
>>> getLogger().debug( "Mapped url: " + to + " to relative path:
>>> " + relativePath );
>>>
>>> }
>>>
>>> - return relativePath;
>>> + return relativePath.toString();
>>>
>>> }
>>>
>>> /** {@inheritDoc} */
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
--
Dennis Lundberg
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: svn commit: r959435 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Posted by Hervé BOUTEMY <he...@free.fr>.
good point.
we have MPIR-80 that should exactly document this, but the proposed
implementation wasn't accepted.
Time to try to implement this feature, IMHO
Le jeudi 01 juillet 2010, Dennis Lundberg a écrit :
> Now that we are starting to use Java 5 code, we should probably document
> somewhere on the site that this component requires Java 5.
>
> There is a prerequisite for Maven 2.2.1 in the POM, but for shared
> components that info doesn't show up anywhere on the generated site.
>
> On 2010-06-30 23:13, hboutemy@apache.org wrote:
> > Author: hboutemy
> > Date: Wed Jun 30 21:13:06 2010
> > New Revision: 959435
> >
> > URL: http://svn.apache.org/viewvc?rev=959435&view=rev
> > Log:
> > use StringBuilder instead of String +=
> >
> > Modified:
> > maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/d
> > oxia/tools/DefaultSiteTool.java
> >
> > Modified:
> > maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
> > a/tools/DefaultSiteTool.java URL:
> > http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/ma
> > in/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=959435&r1=9
> > 59434&r2=959435&view=diff
> > ========================================================================
> > ====== ---
> > maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
> > a/tools/DefaultSiteTool.java (original) +++
> > maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxi
> > a/tools/DefaultSiteTool.java Wed Jun 30 21:13:06 2010 @@ -356,43 +356,43
> > @@ public class DefaultSiteTool
> >
> > toTokeniser.nextToken();
> >
> > }
> >
> > - String relativePath = "";
> > + StringBuilder relativePath = new StringBuilder();
> >
> > // add back refs for the rest of from location.
> > while ( fromTokeniser.hasMoreTokens() )
> > {
> >
> > fromTokeniser.nextToken();
> >
> > - relativePath += "..";
> > + relativePath.append( ".." );
> >
> > if ( fromTokeniser.hasMoreTokens() )
> > {
> >
> > - relativePath += File.separatorChar;
> > + relativePath.append( File.separatorChar );
> >
> > }
> >
> > }
> >
> > if ( relativePath.length() != 0 && toTokeniser.hasMoreTokens() )
> > {
> >
> > - relativePath += File.separatorChar;
> > + relativePath.append( File.separatorChar );
> >
> > }
> >
> > // add fwd fills for whatever's left of to.
> > while ( toTokeniser.hasMoreTokens() )
> > {
> >
> > - relativePath += toTokeniser.nextToken();
> > + relativePath.append( toTokeniser.nextToken() );
> >
> > if ( toTokeniser.hasMoreTokens() )
> > {
> >
> > - relativePath += File.separatorChar;
> > + relativePath.append( File.separatorChar );
> >
> > }
> >
> > }
> >
> > - if ( !relativePath.equals( to ) )
> > + if ( getLogger().isDebugEnabled() && !relativePath.equals( to )
> > )
> >
> > {
> >
> > getLogger().debug( "Mapped url: " + to + " to relative path:
> > " + relativePath );
> >
> > }
> >
> > - return relativePath;
> > + return relativePath.toString();
> >
> > }
> >
> > /** {@inheritDoc} */
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org