org.codehaus.mojo.scmchangelog.scm
Class ScmAdapterFactory

java.lang.Object
  extended by org.codehaus.mojo.scmchangelog.scm.ScmAdapterFactory

public class ScmAdapterFactory
extends Object

The utility class to separate the report from the scm secific implementations.

Version:
$Id$
Author:
ehsavoie

Constructor Summary
ScmAdapterFactory()
           
 
Method Summary
static ScmAdapter getInstance(org.apache.maven.scm.manager.ScmManager currentManager, GrammarEnum currentGrammar, org.apache.maven.scm.repository.ScmRepository repository, Log logger)
          Create the instance of ScmAdpater corresponding to the current Scm.
static void registerProviders(org.apache.maven.scm.manager.ScmManager manager, GrammarEnum grammar, Log logger, Pattern pattern)
          Register the scm providers supported by this plugin.
static void setTagBase(org.apache.maven.scm.repository.ScmRepository repository, String tagBase)
          Defines the base url to access tags.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ScmAdapterFactory

public ScmAdapterFactory()
Method Detail

getInstance

public static final ScmAdapter getInstance(org.apache.maven.scm.manager.ScmManager currentManager,
                                           GrammarEnum currentGrammar,
                                           org.apache.maven.scm.repository.ScmRepository repository,
                                           Log logger)
Create the instance of ScmAdpater corresponding to the current Scm.

Parameters:
currentManager - the ScmManager
currentGrammar - the grammar.
repository - the ScmRepository.
logger - thelogger.
Returns:
a ScmAdapter for the current SCM.

registerProviders

public static final void registerProviders(org.apache.maven.scm.manager.ScmManager manager,
                                           GrammarEnum grammar,
                                           Log logger,
                                           Pattern pattern)
Register the scm providers supported by this plugin.

Parameters:
manager - the Scm manager.
grammar - the selected grammar for extracting comments.
logger - the current logger.
pattern - the regexp pattern to filter tags and branches names.

setTagBase

public static final void setTagBase(org.apache.maven.scm.repository.ScmRepository repository,
                                    String tagBase)
Defines the base url to access tags. This is used only in the case of a svn repository.

Parameters:
repository - the scm repository.
tagBase - the url to the tags.


Copyright © 2008-2009 Codehaus. All Rights Reserved.