org.apache.maven.scm.provider

Interface ScmProvider

public interface ScmProvider

Version: $Id: ScmProvider.java 386265 2006-03-16 05:33:09Z carlos $

Author: Emmanuel Venisse

Field Summary
StringROLE
Method Summary
AddScmResultadd(ScmRepository repository, ScmFileSet fileSet)
Adds the given files to the source control system
voidaddListener(ScmLogger logger)
ChangeLogScmResultchangeLog(ScmRepository repository, ScmFileSet fileSet, Date startDate, Date endDate, int numDays, String branch)
Returns the changes that have happend in the source control system in a certain period of time.
ChangeLogScmResultchangeLog(ScmRepository repository, ScmFileSet fileSet, Date startDate, Date endDate, int numDays, String branch, String datePattern)
Returns the changes that have happend in the source control system in a certain period of time.
ChangeLogScmResultchangeLog(ScmRepository repository, ScmFileSet fileSet, String startTag, String endTag)
Returns the changes that have happend in the source control system between two tags.
ChangeLogScmResultchangeLog(ScmRepository repository, ScmFileSet fileSet, String startTag, String endTag, String datePattern)
Returns the changes that have happend in the source control system between two tags.
CheckInScmResultcheckIn(ScmRepository repository, ScmFileSet fileSet, String tag, String message)
Save the changes you have done into the repository.
CheckOutScmResultcheckOut(ScmRepository repository, ScmFileSet fileSet, String tag)
Create a copy of the repository on your local machine
DiffScmResultdiff(ScmRepository repository, ScmFileSet fileSet, String startRevision, String endRevision)
EditScmResultedit(ScmRepository repository, ScmFileSet fileSet)
Make a file editable.
StringgetScmSpecificFilename()
Returns the scm reserved file name where the SCM stores information like 'CVS', '.svn'.
StringgetScmType()
ScmProviderRepositorymakeProviderScmRepository(String scmSpecificUrl, char delimiter)
ScmProviderRepositorymakeProviderScmRepository(File path)
RemoveScmResultremove(ScmRepository repository, ScmFileSet fileSet, String message)
Removes the given files from the source control system
booleanrequiresEditMode()
StatusScmResultstatus(ScmRepository repository, ScmFileSet fileSet)
Returns the status of the files in the source control system.
TagScmResulttag(ScmRepository repository, ScmFileSet fileSet, String tag)
Tag (or label in some systems) will tag the source file with a certain tag
UnEditScmResultunedit(ScmRepository repository, ScmFileSet fileSet)
Make a file no longer editable.
UpdateScmResultupdate(ScmRepository repository, ScmFileSet fileSet, String tag)
Updates the copy on the local machine with the changes in the repository
UpdateScmResultupdate(ScmRepository repository, ScmFileSet fileSet, String tag, String datePattern)
Updates the copy on the local machine with the changes in the repository
UpdateScmResultupdate(ScmRepository repository, ScmFileSet fileSet, String tag, Date lastUpdate)
Updates the copy on the local machine with the changes in the repository
UpdateScmResultupdate(ScmRepository repository, ScmFileSet fileSet, String tag, Date lastUpdate, String datePattern)
Updates the copy on the local machine with the changes in the repository
ListvalidateScmUrl(String scmSpecificUrl, char delimiter)

Field Detail

ROLE

public String ROLE

Method Detail

add

public AddScmResult add(ScmRepository repository, ScmFileSet fileSet)
Adds the given files to the source control system

Parameters: repository the source control system fileSet the files to be added

Returns: an AddScmResult that contains the files that have been added

Throws: ScmException

addListener

public void addListener(ScmLogger logger)

changeLog

public ChangeLogScmResult changeLog(ScmRepository repository, ScmFileSet fileSet, Date startDate, Date endDate, int numDays, String branch)
Returns the changes that have happend in the source control system in a certain period of time. This can be adding, removing, updating, ... of files

Parameters: repository the source control system fileSet the files to know the changes about. Implementations can also give the changes from the getBasedir downwards. startDate the start date of the period endDate the end date of the period numDays branch

Returns:

Throws: ScmException

changeLog

public ChangeLogScmResult changeLog(ScmRepository repository, ScmFileSet fileSet, Date startDate, Date endDate, int numDays, String branch, String datePattern)
Returns the changes that have happend in the source control system in a certain period of time. This can be adding, removing, updating, ... of files

Parameters: repository the source control system fileSet the files to know the changes about. Implementations can also give the changes from the getBasedir downwards. startDate the start date of the period endDate the end date of the period numDays branch datePattern the date pattern use in changelog output returned by scm tool

Returns:

Throws: ScmException

changeLog

public ChangeLogScmResult changeLog(ScmRepository repository, ScmFileSet fileSet, String startTag, String endTag)
Returns the changes that have happend in the source control system between two tags. This can be adding, removing, updating, ... of files

Parameters: repository the source control system fileSet the files to know the changes about. Implementations can also give the changes from the getBasedir downwards. startTag the start tag endTag the end tag

Returns:

Throws: ScmException

changeLog

public ChangeLogScmResult changeLog(ScmRepository repository, ScmFileSet fileSet, String startTag, String endTag, String datePattern)
Returns the changes that have happend in the source control system between two tags. This can be adding, removing, updating, ... of files

Parameters: repository the source control system fileSet the files to know the changes about. Implementations can also give the changes from the getBasedir downwards. startTag the start tag endTag the end tag datePattern the date pattern use in changelog output returned by scm tool

Returns:

Throws: ScmException

checkIn

public CheckInScmResult checkIn(ScmRepository repository, ScmFileSet fileSet, String tag, String message)
Save the changes you have done into the repository. This will create a new version of the file or directory in the repository.

Parameters: repository the source control system fileSet the files to check in (sometimes called commit) tag message a string that is a comment on the changes that where done

Returns:

Throws: ScmException

checkOut

public CheckOutScmResult checkOut(ScmRepository repository, ScmFileSet fileSet, String tag)
Create a copy of the repository on your local machine

Parameters: repository the source control system fileSet the files are copied to the getBasedir location tag get the version defined by the tag

Returns:

Throws: ScmException

diff

public DiffScmResult diff(ScmRepository repository, ScmFileSet fileSet, String startRevision, String endRevision)

edit

public EditScmResult edit(ScmRepository repository, ScmFileSet fileSet)
Make a file editable. This is used in source control systems where you look at read-only files and you need to make them not read-only anymore before you can edit them. This can also mean that no other user in the system can make the file not read-only anymore.

Parameters: repository the source control system fileSet the files to make editable

Returns:

Throws: ScmException

getScmSpecificFilename

public String getScmSpecificFilename()
Returns the scm reserved file name where the SCM stores information like 'CVS', '.svn'.

Returns: the scm reserved file name

getScmType

public String getScmType()

makeProviderScmRepository

public ScmProviderRepository makeProviderScmRepository(String scmSpecificUrl, char delimiter)

makeProviderScmRepository

public ScmProviderRepository makeProviderScmRepository(File path)

remove

public RemoveScmResult remove(ScmRepository repository, ScmFileSet fileSet, String message)
Removes the given files from the source control system

Parameters: repository the source control system fileSet the files to be removed message

Returns:

Throws: ScmException

requiresEditMode

public boolean requiresEditMode()

status

public StatusScmResult status(ScmRepository repository, ScmFileSet fileSet)
Returns the status of the files in the source control system. The state of each file can be one of the ScmFileStatus flags.

Parameters: repository the source control system fileSet the files to know the status about. Implementations can also give the changes from the getBasedir downwards.

Returns:

Throws: ScmException

tag

public TagScmResult tag(ScmRepository repository, ScmFileSet fileSet, String tag)
Tag (or label in some systems) will tag the source file with a certain tag

Parameters: repository the source control system fileSet the files to tag. Implementations can also give the changes from the getBasedir downwards. tag the tag to apply to the files

Returns:

Throws: ScmException

unedit

public UnEditScmResult unedit(ScmRepository repository, ScmFileSet fileSet)
Make a file no longer editable. This is the conterpart of ScmProvider. It makes the file read-only again.

Parameters: repository the source control system fileSet the files to make uneditable

Returns:

Throws: ScmException

update

public UpdateScmResult update(ScmRepository repository, ScmFileSet fileSet, String tag)
Updates the copy on the local machine with the changes in the repository

Parameters: repository the source control system fileSet location of your local copy tag use the version defined by the tag

Returns:

Throws: ScmException

update

public UpdateScmResult update(ScmRepository repository, ScmFileSet fileSet, String tag, String datePattern)
Updates the copy on the local machine with the changes in the repository

Parameters: repository the source control system fileSet location of your local copy tag use the version defined by the tag datePattern the date pattern use in changelog output returned by scm tool

Returns:

Throws: ScmException

update

public UpdateScmResult update(ScmRepository repository, ScmFileSet fileSet, String tag, Date lastUpdate)
Updates the copy on the local machine with the changes in the repository

Parameters: repository the source control system fileSet location of your local copy tag use the version defined by the tag lastUpdate

Returns:

Throws: ScmException

update

public UpdateScmResult update(ScmRepository repository, ScmFileSet fileSet, String tag, Date lastUpdate, String datePattern)
Updates the copy on the local machine with the changes in the repository

Parameters: repository the source control system fileSet location of your local copy tag use the version defined by the tag lastUpdate Date of last update datePattern the date pattern use in changelog output returned by scm tool

Returns:

Throws: ScmException

validateScmUrl

public List validateScmUrl(String scmSpecificUrl, char delimiter)
Copyright © 2003-2009 Apache Software Foundation. All Rights Reserved.