Class SVNStatusReporter
- java.lang.Object
-
- org.tmatesoft.svn.core.internal.wc.SVNStatusReporter
-
- All Implemented Interfaces:
ISVNReporter
,ISVNReporterBaton
public class SVNStatusReporter extends java.lang.Object implements ISVNReporterBaton, ISVNReporter
- Version:
- 1.3
-
-
Field Summary
Fields Modifier and Type Field Description private ISVNReporterBaton
myBaton
private SVNURL
myCommonAncestorLocation
private SVNStatusEditor
myEditor
private java.util.Map
myLocks
private ISVNReporter
myReporter
private SVNRepository
myRepository
private SVNURL
myRepositoryRoot
-
Constructor Summary
Constructors Constructor Description SVNStatusReporter(SVNRepository repos, ISVNReporterBaton baton, SVNStatusEditor editor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
abortReport()
Aborts the current running report due to errors occured.void
deletePath(java.lang.String path)
Describes a working copypath
as deleted or missing.void
finishReport()
Finalizes the report.SVNLock
getLock(SVNURL url)
void
linkPath(SVNURL url, java.lang.String path, java.lang.String lockToken, long revision, boolean startEmpty)
Describes a local path as being at a particular revision to switch the path to a different repository location.void
linkPath(SVNURL url, java.lang.String path, java.lang.String lockToken, long revision, SVNDepth depth, boolean startEmpty)
Describes a local path as being at a particular revision to switch the path to a different repository location.void
report(ISVNReporter reporter)
Makes a report describing the state of local items in order to get the differences between the local items and what actually is in a repository.void
setPath(java.lang.String path, java.lang.String lockToken, long revision, boolean startEmpty)
Describes a local path as being at a particular revision.void
setPath(java.lang.String path, java.lang.String lockToken, long revision, SVNDepth depth, boolean startEmpty)
Describes a working copypath
as being at a particularrevision
and having depthdepth
.
-
-
-
Field Detail
-
myReporter
private ISVNReporter myReporter
-
myBaton
private ISVNReporterBaton myBaton
-
myCommonAncestorLocation
private SVNURL myCommonAncestorLocation
-
myRepository
private SVNRepository myRepository
-
myRepositoryRoot
private SVNURL myRepositoryRoot
-
myLocks
private java.util.Map myLocks
-
myEditor
private SVNStatusEditor myEditor
-
-
Constructor Detail
-
SVNStatusReporter
public SVNStatusReporter(SVNRepository repos, ISVNReporterBaton baton, SVNStatusEditor editor)
-
-
Method Detail
-
report
public void report(ISVNReporter reporter) throws SVNException
Description copied from interface:ISVNReporterBaton
Makes a report describing the state of local items in order to get the differences between the local items and what actually is in a repository.- Specified by:
report
in interfaceISVNReporterBaton
- Parameters:
reporter
- a reporter passed to make reports- Throws:
SVNException
-
setPath
public void setPath(java.lang.String path, java.lang.String lockToken, long revision, boolean startEmpty) throws SVNException
Description copied from interface:ISVNReporter
Describes a local path as being at a particular revision.
If
startEmpty
is true and thepath
is a directory, an implementor should assume the directory has no entries or properties (used in checkouts and aborted updates).A next call to this method will "override" any previous
setPath()
calls made on parent paths. Thepath
is relative to the repository location specified for an SVNRepository driver.- Specified by:
setPath
in interfaceISVNReporter
- Parameters:
path
- a local item's pathlockToken
- if not null, it is a lock token for thepath
revision
- the local item's revision numberstartEmpty
- if true and if thepath
is a directory, then means there're no entries yet- Throws:
SVNException
- in case the repository could not be connected
-
deletePath
public void deletePath(java.lang.String path) throws SVNException
Description copied from interface:ISVNReporter
Describes a working copypath
as deleted or missing.- Specified by:
deletePath
in interfaceISVNReporter
- Parameters:
path
- a path relative to the root of the report- Throws:
SVNException
- in case the repository could not be connected
-
linkPath
public void linkPath(SVNURL url, java.lang.String path, java.lang.String lockToken, long revision, boolean startEmpty) throws SVNException
Description copied from interface:ISVNReporter
Describes a local path as being at a particular revision to switch the path to a different repository location. LikesetPath()
, but differs in that the local item'spath
(relative to the root of the report driver) isn't a reflection of the path in the repository, but is instead a reflection of a different repository path at arevision
. IfstartEmpty
is set and thepath
is a directory, the implementor should assume the directory has no entries or properties.- Specified by:
linkPath
in interfaceISVNReporter
- Parameters:
url
- a new repository location to switch topath
- the local item's pathlockToken
- if not null, it is a lock token for thepath
revision
- the local item's revision numberstartEmpty
- if true and if thepath
is a directory, then means there're no entries yet- Throws:
SVNException
- in case the repository could not be connected
-
finishReport
public void finishReport() throws SVNException
Description copied from interface:ISVNReporter
Finalizes the report. Must be called when having traversed a local tree of paths.Any directories or files not explicitly set (described) are assumed to be at the baseline revision.
- Specified by:
finishReport
in interfaceISVNReporter
- Throws:
SVNException
- in case the repository could not be connected
-
abortReport
public void abortReport() throws SVNException
Description copied from interface:ISVNReporter
Aborts the current running report due to errors occured.If an error occurs during a report, call this method to abort the reporter correctly.
- Specified by:
abortReport
in interfaceISVNReporter
- Throws:
SVNException
- in case the repository could not be connected
-
linkPath
public void linkPath(SVNURL url, java.lang.String path, java.lang.String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException
Description copied from interface:ISVNReporter
Describes a local path as being at a particular revision to switch the path to a different repository location. LikeISVNReporter.setPath(String, String, long, SVNDepth, boolean)
, but differs in that the local item'spath
(relative to the root of the report driver) isn't a reflection of the path in the repository, but is instead a reflection of a different repositoryurl
atrevision
, and has depthdepth
.path
may not be underneath a path on whichISVNReporter.setPath(String, String, long, SVNDepth, boolean)
was previously called withSVNDepth.EXCLUDE
in this report. IfstartEmpty
is set andpath
is a directory, that will mean that the directory has no entries or props. IflockToken
is non-null, it is the lock token forpath
in the local tree.- Specified by:
linkPath
in interfaceISVNReporter
- Parameters:
url
- a new repository location to switch topath
- the local item's pathlockToken
- if not null, it is a lock token for thepath
revision
- the local item's revision numberdepth
- depth ofpath
startEmpty
- if true and if thepath
is a directory, then means there're no entries yet- Throws:
SVNException
- in case the repository could not be connected
-
setPath
public void setPath(java.lang.String path, java.lang.String lockToken, long revision, SVNDepth depth, boolean startEmpty) throws SVNException
Description copied from interface:ISVNReporter
Describes a working copypath
as being at a particularrevision
and having depthdepth
.revision
may be invalid (<0
) if (for example)path
represents a locally-added path with no revision number, ordepth
isSVNDepth.EXCLUDE
.path
may not be underneath a path on whichsetPath()
was previously called withSVNDepth.EXCLUDE
in this report. IfstartEmpty
is set andpath
is a directory, this will mean that the directory has no entries or properties. This will *override* any previoussetPath()
calls made on parent paths.path
is relative to thelocation
of the repository access object. IflockToken
is non-null, it is the lock token forpath
in the local tree.- Specified by:
setPath
in interfaceISVNReporter
- Parameters:
path
- a local item's pathlockToken
- if not null, it is a lock token for thepath
revision
- the local item's revision numberdepth
- depth ofpath
startEmpty
- if true and if thepath
is a directory, then means there're no entries yet- Throws:
SVNException
- in case the repository could not be connected
-
-