Class SvnChangeDetector
- java.lang.Object
-
- com.atlassian.bamboo.repository.svn.v2.AbstractSvnExecutor
-
- com.atlassian.bamboo.repository.svn.v2.SvnChangeDetector
-
- All Implemented Interfaces:
CommitsIsolatingVcsChangeDetector
,IdentifyingExecutor<VcsChangeDetector>
,VcsChangeDetector
public class SvnChangeDetector extends AbstractSvnExecutor implements CommitsIsolatingVcsChangeDetector
-
-
Field Summary
-
Fields inherited from class com.atlassian.bamboo.repository.svn.v2.AbstractSvnExecutor
customVariableContext, svnClientManagerFactory
-
-
Constructor Summary
Constructors Constructor Description SvnChangeDetector()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull BuildRepositoryChanges
collectChangesForRevision(@NotNull PlanKey planKey, @NotNull VcsRepositoryData repositoryData, @NotNull String customRevision)
@NotNull BuildRepositoryChanges
collectChangesSinceRevision(@NotNull PlanKey planKey, @NotNull VcsRepositoryData repositoryData, @NotNull PlanVcsRevisionData revisionData)
@Nullable ContextualVcsId<VcsChangeDetector>
getVcsIdForExecutor(@NotNull VcsRepositoryData vcsRepositoryData)
Returned id has to fulfill the following: Given two VcsRepositoryData objects A and B, and executor e returning equal ContextualVcsId (in terms of equals()), for any operation foo() provided by the executor, the calls e::foo(A) and e::foo(B) should be equivalent.@NotNull List<BuildRepositoryChanges>
isolateCommits(@NotNull BuildRepositoryChanges changes, @NotNull VcsRepositoryData vcsRepositoryData)
Break the single build changes object into a list ofBuildRepositoryChanges
.-
Methods inherited from class com.atlassian.bamboo.repository.svn.v2.AbstractSvnExecutor
checkPathExists, copyRepository, doInfo, extractTrustedKey, getBranchDetectionRootUrl, getBranchRootUrl, getCommits, getSubstitutedAccessData, getSubstitutedAccessDataBuilder, getSvnClientManager, getTagRootUrl, getWorkingCopyFormatFromConfiguration, substituteString, svnUrltoVcsBranch
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.bamboo.vcs.runtime.VcsChangeDetector
collectChangesForInitialBuild
-
-
-
-
Method Detail
-
collectChangesForRevision
@NotNull public @NotNull BuildRepositoryChanges collectChangesForRevision(@NotNull @NotNull PlanKey planKey, @NotNull @NotNull VcsRepositoryData repositoryData, @NotNull @NotNull String customRevision) throws RepositoryException
- Specified by:
collectChangesForRevision
in interfaceVcsChangeDetector
- Throws:
RepositoryException
-
collectChangesSinceRevision
@NotNull public @NotNull BuildRepositoryChanges collectChangesSinceRevision(@NotNull @NotNull PlanKey planKey, @NotNull @NotNull VcsRepositoryData repositoryData, @NotNull @NotNull PlanVcsRevisionData revisionData) throws RepositoryException
- Specified by:
collectChangesSinceRevision
in interfaceVcsChangeDetector
- Throws:
RepositoryException
-
getVcsIdForExecutor
@Nullable public @Nullable ContextualVcsId<VcsChangeDetector> getVcsIdForExecutor(@NotNull @NotNull VcsRepositoryData vcsRepositoryData)
Description copied from interface:IdentifyingExecutor
Returned id has to fulfill the following: Given two VcsRepositoryData objects A and B, and executor e returning equal ContextualVcsId (in terms of equals()), for any operation foo() provided by the executor, the calls e::foo(A) and e::foo(B) should be equivalent. To be more precise: given any time point t and any variable context v, calling a::foo(A) should yield the same results as calling e::foo(B). Given the above it follows that - calculation of the id should take into account global and plan variables. This means, that calling this method on the same object in different variable context can (possibly must) yield different results. - equal ids need not (and should not) guarantee equal call results over indefinite time. In particular, result of e:foo(A).equals(e::foo(A)) is allowed to be false, since 2 calls to e::foo(A) do not happen at the same time. Example: 2 git repositories with the same url and credentials are considered equal in context ofVcsBranchDetector
. If they also point to the same branch, they are considered equal in context ofVcsChangeDetector
- Specified by:
getVcsIdForExecutor
in interfaceIdentifyingExecutor<VcsChangeDetector>
- Returns:
- the id of repository, can be null if no feasible identification algorithm exists
-
isolateCommits
@NotNull public @NotNull List<BuildRepositoryChanges> isolateCommits(@NotNull @NotNull BuildRepositoryChanges changes, @NotNull @NotNull VcsRepositoryData vcsRepositoryData)
Description copied from interface:CommitsIsolatingVcsChangeDetector
Break the single build changes object into a list ofBuildRepositoryChanges
. Must not be null. May return an empty list but that doesn't actually make any sense.
The order here matters. The first of theBuildRepositoryChanges
will be more likely to be built than lower changes, which may be discarded.- Specified by:
isolateCommits
in interfaceCommitsIsolatingVcsChangeDetector
- Returns:
-
-