org.openengsb.domain.scm
Interface ScmDomain

All Superinterfaces:
org.openengsb.core.api.Domain, org.openengsb.core.api.OpenEngSBService

public interface ScmDomain
extends org.openengsb.core.api.Domain

ScmDomain is an abstraction for working with SCM tools.


Method Summary
 CommitRef add(String comment, File... file)
          Adds one or more File existing in the working directory to the repository and commits them with the passed comment.
 boolean exists(String file)
          Check if file identified by its fileName exists in the HEAD revision and returns true if it does.
 boolean exists(String fileName, CommitRef version)
          Check if file identified by its fileName exists in a revision identified by the CommitRef and returns true if it does.
 File export()
          Exports the files and directories of the HEAD revision from a repository without the SCM specific data in a compressed format.
 File export(CommitRef ref)
          Exports the files and directories of a revision identified by the CommitRef from a repository without the SCM specific data in a compressed format.
 File get(String file)
          Retrieves a single File from a repository identified by its fileName if it exists in the HEAD revision.
 File get(String fileName, CommitRef ref)
          Retrieves a single File from a repository identified by its fileName if it exists in the revision identified by the CommitRef.
 CommitRef getCommitRefForTag(TagRef ref)
          Resolves and returns the CommitRef for a TagRef or null if the reference does not exist.
 CommitRef getHead()
          Returns the CommitRef of the current HEAD in the repository or null.
 CommitRef remove(String comment, File... file)
          Removes one or more File from the working directory of the repository and commits them with a passed comment.
 TagRef tagRepo(String tagName)
          Tags the actual HEAD of the repository with the passed tagName and returns the corresponding TagRef or null.
 TagRef tagRepo(String tagName, CommitRef ref)
          Tags the commit of the repository identified by the CommitRef with the passed tagName and returns the corresponding TagRef or null.
 List<CommitRef> update()
          Looks up changes in a remote repository and updates the local repository or checks out a new local repository and returns a list of CommitRef with the revisions produced since the last update or null.
 
Methods inherited from interface org.openengsb.core.api.Domain
getAliveState
 
Methods inherited from interface org.openengsb.core.api.OpenEngSBService
getInstanceId
 

Method Detail

update

List<CommitRef> update()
Looks up changes in a remote repository and updates the local repository or checks out a new local repository and returns a list of CommitRef with the revisions produced since the last update or null.


export

File export()
Exports the files and directories of the HEAD revision from a repository without the SCM specific data in a compressed format.


export

File export(CommitRef ref)
Exports the files and directories of a revision identified by the CommitRef from a repository without the SCM specific data in a compressed format.


exists

boolean exists(String file)
Check if file identified by its fileName exists in the HEAD revision and returns true if it does.


get

File get(String file)
Retrieves a single File from a repository identified by its fileName if it exists in the HEAD revision. If the file does not exist in the revision null will be returned.


exists

boolean exists(String fileName,
               CommitRef version)
Check if file identified by its fileName exists in a revision identified by the CommitRef and returns true if it does.


get

File get(String fileName,
         CommitRef ref)
Retrieves a single File from a repository identified by its fileName if it exists in the revision identified by the CommitRef. If the file does not exist in the revision null will be returned.


getHead

CommitRef getHead()
Returns the CommitRef of the current HEAD in the repository or null.


add

CommitRef add(String comment,
              File... file)
Adds one or more File existing in the working directory to the repository and commits them with the passed comment. Returns the CommitRef of the commit triggered.


remove

CommitRef remove(String comment,
                 File... file)
Removes one or more File from the working directory of the repository and commits them with a passed comment. Returns the CommitRef of the commit triggered.


tagRepo

TagRef tagRepo(String tagName)
Tags the actual HEAD of the repository with the passed tagName and returns the corresponding TagRef or null.


tagRepo

TagRef tagRepo(String tagName,
               CommitRef ref)
Tags the commit of the repository identified by the CommitRef with the passed tagName and returns the corresponding TagRef or null.


getCommitRefForTag

CommitRef getCommitRefForTag(TagRef ref)
Resolves and returns the CommitRef for a TagRef or null if the reference does not exist.



Copyright © 2009-2011. All Rights Reserved.