Package org.apache.maven.scm.provider.hg
Class HgScmProvider
- java.lang.Object
-
- org.apache.maven.scm.provider.AbstractScmProvider
-
- org.apache.maven.scm.provider.hg.HgScmProvider
-
- All Implemented Interfaces:
ScmProvider
@Singleton @Named("hg") public class HgScmProvider extends AbstractScmProvider
Mercurial (HG) is a decentralized revision control system. http://www.selenic.com/mercurial- Author:
- thurner rupert
-
-
Field Summary
-
Fields inherited from class org.apache.maven.scm.provider.AbstractScmProvider
logger
-
-
Constructor Summary
Constructors Constructor Description HgScmProvider()
-
Method Summary
-
Methods inherited from class org.apache.maven.scm.provider.AbstractScmProvider
add, add, add, blame, blame, branch, branch, branch, changeLog, changeLog, changeLog, changeLog, changeLog, changeLog, changeLog, changeLog, changeLog, checkIn, checkIn, checkIn, checkIn, checkOut, checkOut, checkOut, checkOut, checkOut, checkOut, checkOut, diff, diff, edit, edit, export, export, export, export, export, export, list, list, login, mkdir, mkdir, remoteInfo, remove, requiresEditMode, sanitizeTagName, status, tag, tag, tag, unedit, unedit, untag, update, update, update, update, update, update, update, update, update, update, update, update, validateTagName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.maven.scm.provider.ScmProvider
setInteractive
-
-
-
-
Constructor Detail
-
HgScmProvider
public HgScmProvider()
-
-
Method Detail
-
getScmSpecificFilename
public String getScmSpecificFilename()
Returns the scm reserved file name where the SCM stores information like '.git', '.svn'.- Specified by:
getScmSpecificFilename
in interfaceScmProvider
- Overrides:
getScmSpecificFilename
in classAbstractScmProvider
- Returns:
- the scm reserved file name
-
makeProviderScmRepository
public ScmProviderRepository makeProviderScmRepository(String scmSpecificUrl, char delimiter) throws ScmRepositoryException
- Throws:
ScmRepositoryException
-
makeProviderScmRepository
public ScmProviderRepository makeProviderScmRepository(File path) throws ScmRepositoryException, UnknownRepositoryStructure
- Specified by:
makeProviderScmRepository
in interfaceScmProvider
- Overrides:
makeProviderScmRepository
in classAbstractScmProvider
- Throws:
ScmRepositoryException
UnknownRepositoryStructure
-
validateScmUrl
public List<String> validateScmUrl(String scmSpecificUrl, char delimiter)
Validate the scm url.- Specified by:
validateScmUrl
in interfaceScmProvider
- Overrides:
validateScmUrl
in classAbstractScmProvider
- Parameters:
scmSpecificUrl
- The SCM urldelimiter
- The delimiter used in the SCM url- Returns:
- Returns a list of messages if the validation failed
-
getScmType
public String getScmType()
-
add
public AddScmResult add(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
TODO: why public? This should be protected, no?- Overrides:
add
in classAbstractScmProvider
- Throws:
ScmException
-
changelog
public ChangeLogScmResult changelog(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
changelog
in classAbstractScmProvider
- Throws:
ScmException
-
checkin
public CheckInScmResult checkin(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
checkin
in classAbstractScmProvider
- Throws:
ScmException
-
checkout
public CheckOutScmResult checkout(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
checkout
in classAbstractScmProvider
- Throws:
ScmException
-
tag
public TagScmResult tag(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
tag
in classAbstractScmProvider
- Throws:
ScmException
-
diff
public DiffScmResult diff(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
diff
in classAbstractScmProvider
- Throws:
ScmException
-
remove
public RemoveScmResult remove(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
remove
in classAbstractScmProvider
- Throws:
ScmException
-
status
public StatusScmResult status(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
status
in classAbstractScmProvider
- Throws:
ScmException
-
update
public UpdateScmResult update(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
update
in classAbstractScmProvider
- Throws:
ScmException
-
blame
protected BlameScmResult blame(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
blame
in classAbstractScmProvider
- Throws:
ScmException
-
branch
public BranchScmResult branch(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
- Overrides:
branch
in classAbstractScmProvider
- Throws:
ScmException
-
list
protected ListScmResult list(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
Description copied from class:AbstractScmProvider
List each element (files and directories) of fileSet as they exist in the repository.- Overrides:
list
in classAbstractScmProvider
- Parameters:
repository
- the source control systemfileSet
- the files to listparameters
- TODO- Returns:
- The list of files in the repository
- Throws:
NoSuchCommandScmException
- unless overriden by subclassScmException
- if any- Since:
- 1.5
-
info
public InfoScmResult info(ScmProviderRepository repository, ScmFileSet fileSet, CommandParameters parameters) throws ScmException
returns result of hg id -i- Specified by:
info
in interfaceScmProvider
- Overrides:
info
in classAbstractScmProvider
- Parameters:
repository
- the source control systemfileSet
- location of your local copyparameters
- some parameters (not use currently but for future use)- Returns:
- if the scm implementation doesn't support "info" result will
null
- Throws:
ScmException
- if any- Since:
- 1.5
- See Also:
AbstractScmProvider.info(org.apache.maven.scm.provider.ScmProviderRepository, org.apache.maven.scm.ScmFileSet, org.apache.maven.scm.CommandParameters)
-
-