org.opensolaris.opengrok.history
Class SubversionRepository

java.lang.Object
  extended by org.opensolaris.opengrok.history.RepositoryInfo
      extended by org.opensolaris.opengrok.history.Repository
          extended by org.opensolaris.opengrok.history.SubversionRepository
All Implemented Interfaces:
java.io.Serializable

public class SubversionRepository
extends Repository

Access to a Subversion repository. TODO The current implementation does not support nested repositories as described in http://svnbook.red-bean.com/en/1.0/ch07s03.html

See Also:
Serialized Form

Field Summary
protected  java.lang.String reposPath
           
 
Fields inherited from class org.opensolaris.opengrok.history.RepositoryInfo
datePattern, directoryName, remote, type, working
 
Constructor Summary
SubversionRepository()
           
 
Method Summary
 Annotation annotate(java.io.File file, java.lang.String revision)
          Annotate the specified revision of a file.
 boolean fileHasAnnotation(java.io.File file)
          Checks whether this parser can annotate files.
 boolean fileHasHistory(java.io.File file)
           
 java.io.InputStream getHistoryGet(java.lang.String parent, java.lang.String basename, java.lang.String rev)
          Get an input stream that I may use to read a speciffic version of a named file.
 boolean isWorking()
          Returns true if this repository is usable in this context (for SCM systems that use external binaries, the binary must be availabe etc)
 void setDirectoryName(java.lang.String directoryName)
          Specify the name of the root directory for this repository.
 void update()
          Update the content in this repository by pulling the changes from the upstream repository..
 
Methods inherited from class org.opensolaris.opengrok.history.Repository
getDateFormat
 
Methods inherited from class org.opensolaris.opengrok.history.RepositoryInfo
getDatePattern, getDirectoryName, getType, isRemote, setDatePattern, setRemote, setType, setWorking
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

reposPath

protected java.lang.String reposPath
Constructor Detail

SubversionRepository

public SubversionRepository()
Method Detail

setDirectoryName

public void setDirectoryName(java.lang.String directoryName)
Description copied from class: RepositoryInfo
Specify the name of the root directory for this repository.

Overrides:
setDirectoryName in class RepositoryInfo
Parameters:
directoryName - the new name of the root directory

getHistoryGet

public java.io.InputStream getHistoryGet(java.lang.String parent,
                                         java.lang.String basename,
                                         java.lang.String rev)
Description copied from class: Repository
Get an input stream that I may use to read a speciffic version of a named file.

Parameters:
parent - the name of the directory containing the file
basename - the name of the file to get
rev - the revision to get
Returns:
An input stream containing the correct revision.

annotate

public Annotation annotate(java.io.File file,
                           java.lang.String revision)
                    throws java.io.IOException
Description copied from class: Repository
Annotate the specified revision of a file.

Parameters:
file - the file to annotate
revision - revision of the file
Returns:
an Annotation object
Throws:
java.io.IOException - if an error occurs

fileHasAnnotation

public boolean fileHasAnnotation(java.io.File file)
Description copied from class: Repository
Checks whether this parser can annotate files.

Returns:
true if annotation is supported

fileHasHistory

public boolean fileHasHistory(java.io.File file)

update

public void update()
            throws java.io.IOException
Description copied from class: Repository
Update the content in this repository by pulling the changes from the upstream repository..

Throws:
java.io.IOException

isWorking

public boolean isWorking()
Description copied from class: RepositoryInfo
Returns true if this repository is usable in this context (for SCM systems that use external binaries, the binary must be availabe etc)

Overrides:
isWorking in class RepositoryInfo
Returns:
true if the HistoryGuru may use the repository