jetbrains.buildServer.vcs
Interface VcsSupportCore

All Superinterfaces:
VcsSupportConfig
All Known Implementing Classes:
ServerVcsSupport, VcsSupport

public interface VcsSupportCore
extends VcsSupportConfig

The entry point for custom VCS support API

Since:
4.5

Method Summary
 boolean allowSourceCaching()
           
 java.lang.String getCurrentVersion(VcsRoot root)
          Returns version mark version control is currently in (like last committed change list number for Perforce, or current date for CVS).
 boolean isCurrentVersionExpensive()
          If the obtaining current version is an expensive operation (see getCurrentVersion(VcsRoot)) the implementation may optimize performance by returning true.
 boolean sourcesUpdatePossibleIfChangesNotFound(VcsRoot root)
          Must return true if source files in the build checkout directory can be updated even if no changes were detected between some versions.
 
Methods inherited from interface jetbrains.buildServer.vcs.VcsSupportConfig
describeVcsRoot, getCheckoutProperties, getDefaultVcsProperties, getDisplayName, getName, getVcsPropertiesProcessor, getVcsSettingsJspFilePath, getVersionComparator, getVersionDisplayName, isAgentSideCheckoutAvailable, isDAGBasedVcs
 

Method Detail

getCurrentVersion

@NotNull
java.lang.String getCurrentVersion(@NotNull
                                           VcsRoot root)
                                   throws VcsException
Returns version mark version control is currently in (like last committed change list number for Perforce, or current date for CVS).

Parameters:
root - - current configuration
Returns:
- current version of repository. This version has to have the same meaning as a VcsModification version
Throws:
VcsException - throw this exception if some problem occurred while collecting changes or changes cannot be collected because of invalid configuration. Localized message will be shown on the web page for the corresponding project.

isCurrentVersionExpensive

boolean isCurrentVersionExpensive()
If the obtaining current version is an expensive operation (see getCurrentVersion(VcsRoot)) the implementation may optimize performance by returning true. In this case collecting changes for the current version will be done without specifying upper version. Otherwise getCurrentVersion(VcsRoot) will be called first and then the result will be passed to the change collector as the upper version.

Returns:
true if the obtaining current version is an expensive operation.
See Also:
CollectChangesPolicy

allowSourceCaching

boolean allowSourceCaching()
Returns:
true if you want TeamCity to use its internal source cache to reuse patches retrieved earlier and minimize patch building. Returning false may have sense if the underlying version control system has its own effective local caching system (e.g. Mercurial).

sourcesUpdatePossibleIfChangesNotFound

boolean sourcesUpdatePossibleIfChangesNotFound(@NotNull
                                               VcsRoot root)
Must return true if source files in the build checkout directory can be updated even if no changes were detected between some versions. This is possible for example if VCS support plugin can't detect changes when a tag/label is moved. Note that if true is returned for some VCS root, plugin should be able to correctly build patch for this VCS root.
For example, if plugin performs changes collecting in the buildPatch method and then creates patch by detected changes, it should create clean patch for VCS root for which it returned true in this method.

Parameters:
root - VCS root
Returns:
see above