com.javaforge.bobber.plugin.archetype
Class BobberArchetype

java.lang.Object
  extended by org.codehaus.plexus.logging.AbstractLogEnabled
      extended by com.javaforge.bobber.plugin.archetype.BobberArchetype
All Implemented Interfaces:
org.apache.maven.archetype.Archetype, org.codehaus.plexus.logging.LogEnabled

public class BobberArchetype
extends org.codehaus.plexus.logging.AbstractLogEnabled
implements org.apache.maven.archetype.Archetype


Field Summary
 
Fields inherited from interface org.apache.maven.archetype.Archetype
ARCHETYPE_DESCRIPTOR, ARCHETYPE_POM, ARCHETYPE_RESOURCES, ROLE
 
Constructor Summary
BobberArchetype()
           
 
Method Summary
protected  void addParamToContext(String key, Object value, org.apache.velocity.VelocityContext context)
           
 void createArchetype(String archetypeGroupId, String archetypeArtifactId, String archetypeVersion, org.apache.maven.artifact.repository.ArtifactRepository localRepository, List remoteRepositories, Map parameters)
           
protected  Object findVariable(String variableName, List variables)
          Find the variable.
protected  List getListOfValues(String s)
           
protected  void processTemplate(Template template, String outputDirectory, org.apache.velocity.VelocityContext context)
           
protected  void processVariables(Iterator variables, org.apache.velocity.VelocityContext context, boolean interactiveMode)
           
 
Methods inherited from class org.codehaus.plexus.logging.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BobberArchetype

public BobberArchetype()
Method Detail

createArchetype

public void createArchetype(String archetypeGroupId,
                            String archetypeArtifactId,
                            String archetypeVersion,
                            org.apache.maven.artifact.repository.ArtifactRepository localRepository,
                            List remoteRepositories,
                            Map parameters)
                     throws org.apache.maven.archetype.ArchetypeNotFoundException,
                            org.apache.maven.archetype.ArchetypeDescriptorException,
                            org.apache.maven.archetype.ArchetypeTemplateProcessingException
Specified by:
createArchetype in interface org.apache.maven.archetype.Archetype
Throws:
org.apache.maven.archetype.ArchetypeNotFoundException
org.apache.maven.archetype.ArchetypeDescriptorException
org.apache.maven.archetype.ArchetypeTemplateProcessingException

addParamToContext

protected void addParamToContext(String key,
                                 Object value,
                                 org.apache.velocity.VelocityContext context)

processVariables

protected void processVariables(Iterator variables,
                                org.apache.velocity.VelocityContext context,
                                boolean interactiveMode)
                         throws org.apache.maven.archetype.ArchetypeTemplateProcessingException
Throws:
org.apache.maven.archetype.ArchetypeTemplateProcessingException

getListOfValues

protected List getListOfValues(String s)

processTemplate

protected void processTemplate(Template template,
                               String outputDirectory,
                               org.apache.velocity.VelocityContext context)
                        throws org.apache.maven.archetype.ArchetypeTemplateProcessingException
Throws:
org.apache.maven.archetype.ArchetypeTemplateProcessingException

findVariable

protected Object findVariable(String variableName,
                              List variables)
Find the variable.

Parameters:
variableName - name
variables - all variables of the artifact
Returns:
variable value or null of not found


Copyright © 2003-2012 MuleSoft, Inc.. All Rights Reserved.