pax_global_header 0000666 0000000 0000000 00000000064 11663270667 0014530 g ustar 00root root 0000000 0000000 52 comment=4d78d1ff3dbdb59bb938d7133e5a4b889a4cb224
plexus-containers1.5-1.5.5/ 0000775 0000000 0000000 00000000000 11663270667 0015447 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/ 0000775 0000000 0000000 00000000000 11663270667 0023322 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/pom.xml 0000664 0000000 0000000 00000001433 11663270667 0024640 0 ustar 00root root 0000000 0000000
4.0.0
org.codehaus.plexus
plexus-containers
1.5.5
plexus-component-annotations
Plexus :: Component Annotations
Plexus Component "Java 5" Annotations, to describe plexus components properties in java sources with
standard annotations instead of javadoc annotations.
plexus-containers1.5-1.5.5/plexus-component-annotations/src/ 0000775 0000000 0000000 00000000000 11663270667 0024111 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/ 0000775 0000000 0000000 00000000000 11663270667 0025035 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/ 0000775 0000000 0000000 00000000000 11663270667 0025756 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/ 0000775 0000000 0000000 00000000000 11663270667 0026545 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/ 0000775 0000000 0000000 00000000000 11663270667 0030340 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/ 0000775 0000000 0000000 00000000000 11663270667 0031660 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/component/0000775 0000000 0000000 00000000000 11663270667 0033662 5 ustar 00root root 0000000 0000000 0000775 0000000 0000000 00000000000 11663270667 0036140 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/component/annotations Component.java 0000664 0000000 0000000 00000003144 11663270667 0040747 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/component/annotations /*
* Copyright (C) 2007 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.codehaus.plexus.component.annotations;
import java.lang.annotation.Documented;
import static java.lang.annotation.ElementType.TYPE;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Target;
/**
* Marks a class as a Plexus component.
*
* @since 1.0-alpha-33
* @version $Id: Component.java 8467 2009-10-05 20:55:48Z hboutemy $
*/
@Documented
@Retention(RUNTIME)
@Target(TYPE)
@Inherited
public @interface Component
{
Class> role();
String hint() default "";
String version() default "";
String alias() default "";
String description() default "";
String lifecycleHandler() default "";
String instantiationStrategy() default "";
String factory() default "";
String type() default "";
String profile() default "";
String composer() default "";
String configurator() default "";
boolean isolatedRealm() default false;
}
Configuration.java 0000664 0000000 0000000 00000002353 11663270667 0041615 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/component/annotations /*
* Copyright (C) 2007 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.codehaus.plexus.component.annotations;
import java.lang.annotation.Documented;
import static java.lang.annotation.ElementType.FIELD;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Target;
/**
* Marks a field as a configuration element with a default value.
*
* @since 1.0-alpha-33
* @version $Id: Configuration.java 8467 2009-10-05 20:55:48Z hboutemy $
*/
@Documented
@Retention(RUNTIME)
@Target(FIELD)
@Inherited
public @interface Configuration
{
String name() default "";
String value();
}
Requirement.java 0000664 0000000 0000000 00000002725 11663270667 0041311 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-annotations/src/main/java/org/codehaus/plexus/component/annotations /*
* Copyright (C) 2007 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.codehaus.plexus.component.annotations;
import java.lang.annotation.Documented;
import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Target;
/**
* Configures a requirement.
*
* @since 1.0-alpha-33
* @version $Id: Requirement.java 8467 2009-10-05 20:55:48Z hboutemy $
*/
@Documented
@Retention(RUNTIME)
@Target({ FIELD, METHOD })
@Inherited
public @interface Requirement
{
Class> role() default Object.class;
String hint() default "";
//
// HACK: This is here to support component requirement lists, which can take a list of hints
//
String[] hints() default {};
boolean optional() default false;
}
plexus-containers1.5-1.5.5/plexus-component-javadoc/ 0000775 0000000 0000000 00000000000 11663270667 0022374 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/pom.xml 0000664 0000000 0000000 00000004732 11663270667 0023717 0 ustar 00root root 0000000 0000000
4.0.0
org.codehaus.plexus
plexus-containers
1.5.5
plexus-component-javadoc
Plexus :: Javadoc Taglets
Plexus Javadoc Taglets to generate additional documentation for plexus components' javadoc from plexus javadoc annotations.
2007
default-tools.jar
java.vendor
Sun Microsystems Inc.
com.sun
tools
1.4.2
system
${java.home}/../lib/tools.jar
run-its
maven.test.skip
!true
maven-invoker-plugin
1.4
true
${project.build.directory}/it
setup
verify
${project.build.directory}/local-repo
src/it/settings.xml
clean
javadoc:javadoc
integration-test
install
run
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/ 0000775 0000000 0000000 00000000000 11663270667 0023163 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/ 0000775 0000000 0000000 00000000000 11663270667 0023577 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/ 0000775 0000000 0000000 00000000000 11663270667 0024660 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/pom.xml 0000664 0000000 0000000 00000003243 11663270667 0026177 0 ustar 00root root 0000000 0000000
4.0.0
org.codehaus.plexus.plexus-javadoc
test
1.0-SNAPSHOT
jar
2008
Test Plexus Tags
org.apache.maven.plugins
maven-javadoc-plugin
2.3
${basedir}/target/site/apidocs
true
private
UTF-8
UTF-8
UTF-8
org.codehaus.plexus.javadoc.PlexusComponentTaglet
org.codehaus.plexus.javadoc.PlexusConfigurationTaglet
org.codehaus.plexus.javadoc.PlexusRequirementTaglet
org.codehaus.plexus
plexus-component-javadoc
@project.version@
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/ 0000775 0000000 0000000 00000000000 11663270667 0025447 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/main/ 0000775 0000000 0000000 00000000000 11663270667 0026373 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/main/java/ 0000775 0000000 0000000 00000000000 11663270667 0027314 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/main/java/plexus/ 0000775 0000000 0000000 00000000000 11663270667 0030634 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/main/java/plexus/test/ 0000775 0000000 0000000 00000000000 11663270667 0031613 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/src/main/java/plexus/test/App.java 0000664 0000000 0000000 00000003237 11663270667 0033203 0 ustar 00root root 0000000 0000000 package plexus.test;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
/**
* App class
*
* @author Vincent Siveton
* @version 1.0
* @plexus.component role="org.codehaus.plexus.test.App" role-hint="app"
*/
public class App
{
/**
* @plexus.configuration default-value="someone"
*/
private String name;
/**
* @plexus.requirement
* role-hint="foo"
*/
private App app;
/**
* The main method
*
* @param args an array of strings that contains the arguments
*/
public static void main( String[] args )
{
System.out.println( "Sample Application." );
}
/**
* Sample method that prints out the parameter string.
*
* @param str The string value to be printed.
*/
protected void sampleMethod( String str )
{
System.out.println( str );
}
}
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/basic/verify.bsh 0000664 0000000 0000000 00000004245 11663270667 0026667 0 ustar 00root root 0000000 0000000 import java.io.*;
import java.util.*;
import java.util.regex.*;
import org.codehaus.plexus.util.*;
setAccessibility( true );
File docsDir = new File( basedir, "target/site/apidocs" );
System.out.println( "Checking for existence of: " + docsDir );
if ( !docsDir.exists() )
{
throw new FileNotFoundException( docsDir + " was not created" );
}
File docFile = new File( docsDir, "plexus/test/App.html" );
System.out.println( "Checking for existence of: " + docFile );
if ( !docFile.isFile() )
{
throw new FileNotFoundException( docFile + " was not created" );
}
String html = FileUtils.fileRead( docFile, "UTF-8" ).replaceAll( "(\r\n)|(\r)|(\n)", "" );
System.out.println( "Checking for documentation of Plexus component" );
String plexusComponent = "
plexus component:"
+ "" + ""
+ "- role:
"
+ "- \"org.codehaus.plexus.test.app\"
"
+ "- role-hint:
" + "- \"app\"
"
+ " |
";
if ( html.toLowerCase( Locale.ENGLISH ).indexOf( ( plexusComponent ).toLowerCase( Locale.ENGLISH ) ) < 0 )
{
throw new IllegalStateException( "Plexus component doc wrong" );
}
System.out.println( "Checking for documentation of Plexus configuration" );
String plexusConfig = "plexus configuration:"
+ ""
+ "- default-value:
"
+ "- \"someone\"
|
";
if ( html.toLowerCase( Locale.ENGLISH ).indexOf( ( plexusConfig ).toLowerCase( Locale.ENGLISH ) ) < 0 )
{
throw new IllegalStateException( "Plexus configuration doc wrong" );
}
System.out.println( "Checking for documentation of Plexus requirement" );
String plexusRequirement = "plexus requirement:"
+ ""
+ "- role-hint:
- \"foo\"
"
+ " |
";
if ( html.toLowerCase( Locale.ENGLISH ).indexOf( ( plexusRequirement ).toLowerCase( Locale.ENGLISH ) ) < 0 )
{
throw new IllegalStateException( "Plexus requirement doc wrong" );
}
return true;
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/it/settings.xml 0000664 0000000 0000000 00000001576 11663270667 0026172 0 ustar 00root root 0000000 0000000
it-repo
true
local.central
@localRepositoryUrl@
true
true
local.central
@localRepositoryUrl@
true
true
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/ 0000775 0000000 0000000 00000000000 11663270667 0024107 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/ 0000775 0000000 0000000 00000000000 11663270667 0025030 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/ 0000775 0000000 0000000 00000000000 11663270667 0025617 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/ 0000775 0000000 0000000 00000000000 11663270667 0027412 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/ 0000775 0000000 0000000 00000000000 11663270667 0030732 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/javadoc/ 0000775 0000000 0000000 00000000000 11663270667 0032341 5 ustar 00root root 0000000 0000000 AbstractPlexusTaglet.java 0000664 0000000 0000000 00000012722 11663270667 0037236 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/javadoc package org.codehaus.plexus.javadoc;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
import java.util.Enumeration;
import java.util.StringTokenizer;
import javax.swing.text.AttributeSet;
import javax.swing.text.MutableAttributeSet;
import javax.swing.text.SimpleAttributeSet;
import com.sun.javadoc.Tag;
import com.sun.tools.doclets.Taglet;
/**
* Abstract Taglet
for Plexus tags.
*
* @see
* http://plexus.codehaus.org/guides/developer-guide/appendices/javadoc-tags-reference.html
*
* @author Vincent Siveton
* @version $Id: AbstractPlexusTaglet.java 7277 2008-04-11 18:12:21Z bentmann $
*/
public abstract class AbstractPlexusTaglet
implements Taglet
{
/** {@inheritDoc} */
public String toString( Tag tag )
{
if ( tag == null )
{
return null;
}
String tagText = tag.text();
MutableAttributeSet att = getAttributes( tagText );
StringBuffer sb = new StringBuffer();
if ( ( att == null ) || ( att.getAttributeCount() == 0 ) )
{
sb.append( "" ).append( getHeader() ).append( "" );
}
else
{
sb.append( "" ).append( getHeader() ).append( ":" );
sb.append( "" );
appendPlexusTag( sb, att );
sb.append( " |
" );
}
return sb.toString();
}
/** {@inheritDoc} */
public String toString( Tag[] tags )
{
if ( tags.length == 0 )
{
return null;
}
boolean hasParameters = false;
for ( int i = 0; i < tags.length; i++ )
{
String tagText = tags[i].text();
MutableAttributeSet att = getAttributes( tagText );
if ( att != null )
{
hasParameters = att.getAttributeCount() > 0;
}
}
StringBuffer sb = new StringBuffer();
sb.append( "" ).append( getHeader() ).append( ( hasParameters ? ":" : "" ) ).append( "" );
sb.append( "" );
for ( int i = 0; i < tags.length; i++ )
{
if ( i > 0 )
{
sb.append( ", " );
}
String tagText = tags[i].text();
appendPlexusTag( sb, getAttributes( tagText ) );
}
sb.append( " |
" );
return sb.toString();
}
/**
* @return the header to display
*/
public abstract String getHeader();
/**
* @param text the Tag text returned by {@link Tag#text()}
* @return a MutableAttributeSet or null if text was null
*/
private MutableAttributeSet getAttributes( String text )
{
if ( text == null || text.trim().length() == 0 )
{
return null;
}
MutableAttributeSet att = new SimpleAttributeSet();
StringTokenizer token = new StringTokenizer( text, " " );
while ( token.hasMoreTokens() )
{
String nextToken = token.nextToken();
StringTokenizer token2 = new StringTokenizer( nextToken, "=" );
if ( token2.countTokens() != 2 )
{
System.err.println( "The annotation '" + getName() + "' has a wrong Plexus annotations: " + text );
continue;
}
String name = token2.nextToken();
String value = token2.nextToken();
att.addAttribute( name, value );
}
return att;
}
/**
* Append the wanted display in the javadoc.
*
* @param sb
* @param att
*/
private static void appendPlexusTag( StringBuffer sb, MutableAttributeSet att )
{
if ( att == null )
{
return;
}
if ( att.getAttributeCount() > 0 )
{
sb.append( "" );
Enumeration names = att.getAttributeNames();
while ( names.hasMoreElements() )
{
Object key = names.nextElement();
Object value = att.getAttribute( key );
if ( value instanceof AttributeSet )
{
// ignored
}
else
{
sb.append( "- " ).append( key ).append( ":
" );
sb.append( "- " ).append( value ).append( "
" );
}
}
sb.append( "
" );
}
}
}
PlexusComponentTaglet.java 0000664 0000000 0000000 00000007703 11663270667 0037440 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/javadoc package org.codehaus.plexus.javadoc;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
import java.util.Map;
import com.sun.tools.doclets.Taglet;
/**
* The @plexus.component tag is used to show that the class it annotates is a plexus component.
* This will add a <component> element to the <components> in components.xml.
* The following parameters are available, but remember the role is required.
* The text in the javadoc tag describing this class is copied into the component's <description> tag.
*
*
*
* Parameter |
* Required |
* Description |
*
*
* role |
* Yes |
* The role that this class provides an implementation for (usually the class name
* of an implemented Interface |
*
*
* role-hint |
* No |
* The hints are used to differentiate multiple implementations of the same role |
*
*
* version |
* No |
* Set the version of the component |
*
*
*
*
* @see
* http://plexus.codehaus.org/guides/developer-guide/appendices/javadoc-tags-reference.html
*
* @author Vincent Siveton
* @version $Id: PlexusComponentTaglet.java 7277 2008-04-11 18:12:21Z bentmann $
*/
public class PlexusComponentTaglet
extends AbstractPlexusTaglet
{
private static final String NAME = "plexus.component";
private static final String HEADER = "Plexus component";
/** {@inheritDoc} */
public String getHeader()
{
return HEADER;
}
/** {@inheritDoc} */
public String getName()
{
return NAME;
}
/** {@inheritDoc} */
public boolean inConstructor()
{
return false;
}
/** {@inheritDoc} */
public boolean inField()
{
return false;
}
/** {@inheritDoc} */
public boolean inMethod()
{
return false;
}
/** {@inheritDoc} */
public boolean inOverview()
{
return false;
}
/** {@inheritDoc} */
public boolean inPackage()
{
return false;
}
/** {@inheritDoc} */
public boolean inType()
{
return true;
}
/** {@inheritDoc} */
public boolean isInlineTag()
{
return false;
}
/**
* Register this Taglet.
*
* @param tagletMap the map to register this tag to.
*/
public static void register( Map tagletMap )
{
PlexusComponentTaglet tag = new PlexusComponentTaglet();
Taglet t = (Taglet) tagletMap.get( tag.getName() );
if ( t != null )
{
tagletMap.remove( tag.getName() );
}
tagletMap.put( tag.getName(), tag );
}
}
PlexusConfigurationTaglet.java 0000664 0000000 0000000 00000006532 11663270667 0040304 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/javadoc package org.codehaus.plexus.javadoc;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
import java.util.Map;
import com.sun.tools.doclets.Taglet;
/**
* The @plexus.configuration tags are used to mark fields in a class for configuration through
* the components.xml.
*
*
*
* Parameter |
* Required |
* Description |
*
*
* default-value |
* Currently |
* The default values are currently required for the <configuration>
* tag to be written to components.xml. |
*
*
*
*
* @see
* http://plexus.codehaus.org/guides/developer-guide/appendices/javadoc-tags-reference.html
*
* @author Vincent Siveton
* @version $Id: PlexusConfigurationTaglet.java 7277 2008-04-11 18:12:21Z bentmann $
*/
public class PlexusConfigurationTaglet
extends AbstractPlexusTaglet
{
private static final String NAME = "plexus.configuration";
private static final String HEADER = "Plexus configuration";
/** {@inheritDoc} */
public String getHeader()
{
return HEADER;
}
/** {@inheritDoc} */
public String getName()
{
return NAME;
}
/** {@inheritDoc} */
public boolean inConstructor()
{
return false;
}
/** {@inheritDoc} */
public boolean inField()
{
return true;
}
/** {@inheritDoc} */
public boolean inMethod()
{
return false;
}
/** {@inheritDoc} */
public boolean inOverview()
{
return false;
}
/** {@inheritDoc} */
public boolean inPackage()
{
return false;
}
/** {@inheritDoc} */
public boolean inType()
{
return false;
}
/** {@inheritDoc} */
public boolean isInlineTag()
{
return false;
}
/**
* Register this Taglet.
*
* @param tagletMap the map to register this tag to.
*/
public static void register( Map tagletMap )
{
PlexusConfigurationTaglet tag = new PlexusConfigurationTaglet();
Taglet t = (Taglet) tagletMap.get( tag.getName() );
if ( t != null )
{
tagletMap.remove( tag.getName() );
}
tagletMap.put( tag.getName(), tag );
}
}
PlexusRequirementTaglet.java 0000664 0000000 0000000 00000010412 11663270667 0037765 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/java/org/codehaus/plexus/javadoc package org.codehaus.plexus.javadoc;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
import java.util.Map;
import com.sun.tools.doclets.Taglet;
/**
* Tagging a field with @plexus.requirement will tell plexus to inject the required component or
* list of components before the component itself is started. Fields can be of the type of the Interface
* defining the component you wish to be injected or of type java.util.List or java.util.Map.
*
* Fields of type java.lang.List will have a list of components injected whereas a field of
* type java.lang.Map will have a mapping in the form of role-hint -> component.
* The role parameter is required if using a List or Map whereas a role-hint is
* not allowed.
*
*
*
* Parameter |
* Required |
* Description |
*
*
* role |
* No. Yes if the field is a List or a Map |
* The role parameter is used to tell plexus what Component role you are interested in.
* For singleton fields their type is used as a default. |
*
*
* role-hint |
* No. Not allowed if the field is a List or a Map |
* Links to the role-hint defined by a component when looking up a component.
* Not allowed with List or Map fields, as they return all role-hints. |
*
*
*
*
* @see
* http://plexus.codehaus.org/guides/developer-guide/appendices/javadoc-tags-reference.html
*
* @author Vincent Siveton
* @version $Id: PlexusRequirementTaglet.java 7277 2008-04-11 18:12:21Z bentmann $
*/
public class PlexusRequirementTaglet
extends AbstractPlexusTaglet
{
private static final String NAME = "plexus.requirement";
private static final String HEADER = "Plexus requirement";
/** {@inheritDoc} */
public String getHeader()
{
return HEADER;
}
/** {@inheritDoc} */
public String getName()
{
return NAME;
}
/** {@inheritDoc} */
public boolean inConstructor()
{
return false;
}
/** {@inheritDoc} */
public boolean inField()
{
return true;
}
/** {@inheritDoc} */
public boolean inMethod()
{
return false;
}
/** {@inheritDoc} */
public boolean inOverview()
{
return false;
}
/** {@inheritDoc} */
public boolean inPackage()
{
return false;
}
/** {@inheritDoc} */
public boolean inType()
{
return false;
}
/** {@inheritDoc} */
public boolean isInlineTag()
{
return false;
}
/**
* Register this Taglet.
*
* @param tagletMap the map to register this tag to.
*/
public static void register( Map tagletMap )
{
PlexusRequirementTaglet tag = new PlexusRequirementTaglet();
Taglet t = (Taglet) tagletMap.get( tag.getName() );
if ( t != null )
{
tagletMap.remove( tag.getName() );
}
tagletMap.put( tag.getName(), tag );
}
}
plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/ 0000775 0000000 0000000 00000000000 11663270667 0025516 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/org/ 0000775 0000000 0000000 00000000000 11663270667 0026305 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/org/codehaus/ 0000775 0000000 0000000 00000000000 11663270667 0030100 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/org/codehaus/plexus/ 0000775 0000000 0000000 00000000000 11663270667 0031420 5 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/org/codehaus/plexus/javadoc/ 0000775 0000000 0000000 00000000000 11663270667 0033027 5 ustar 00root root 0000000 0000000 package.html 0000775 0000000 0000000 00000002630 11663270667 0035235 0 ustar 00root root 0000000 0000000 plexus-containers1.5-1.5.5/plexus-component-javadoc/src/main/javadoc/org/codehaus/plexus/javadoc
Javadoc Tags used by Plexus tools
Here is a reference of the Javadoc annotations that can be used to 'decorate' the Java sources
to allow Plexus tools like Component Descriptor Creator (CDC) to generate Component Descriptors.
Tag/Annotation |
Available on |
Required |
Descriptor Element |
@plexus.component |
Class |
Yes |
Indicate to Plexus CDC that the class is a component |
@plexus.configuration |
Field |
No |
Tell Plexus CDC that this item should be configured through
the components.xml |
@plexus.requirement |
Field | No |
Indicate to Plexus CDC that the field is required by the component |