| java.lang.Object | ||
| ↳ | com.atlassian.bitbucket.commit.AbstractCommitsRequest | |
| ↳ | com.atlassian.bitbucket.commit.CommitsBetweenRequest | |
Defines a request to retrieve commits "between" sets of included and excluded commits, potentially filtering by paths.
The easiest way to understand commits "between" is with an illustration:
"feature-B" FB1 -- FB2 -- FB3
/ /
/ /
"master" ---- A ---- B ---- C
\
\
"feature-A" FA1 -- FA2 -- FA3
Given the graph above, here are some examples of the commits "between" various points:
from ref and the
current to ref yields the just the added
commitsrescope event.
Also useful when dealing with pull requests is the ability to determine the commits between two repositories.
When a secondary repository is specified its commits will be made available in
the primary repository, which allows retrieving the commits that have been added on a
branch in a fork, for example, when opening a pull request back to its origin. When a secondary repository is
specified, it must be from the same hierarchy as the primary repository or
an exception will be thrown while building the request.
Warning: Retrieving commits between repositories may be expensive. Additionally, when referring
to commits in the secondary repository, includes and
excludes must be specified by hash. Branch and tag names are always resolved
using the primary repository, which may lead to unexpected results.
Note: Once built, a request is immutable. None of the returned
collections may be modified.
| Nested Classes | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| CommitsBetweenRequest.Builder | |||||||||||
|
[Expand]
Inherited Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.atlassian.bitbucket.commit.AbstractCommitsRequest
| |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Retrieves commits, which may be identified by branch or tag name or by hash, which should be excluded from
the results.
| |||||||||||
Retrieves commits, which may be identified by branch or tag name or by hash, which should be included in the
results.
| |||||||||||
Retrieves paths, which may identify directories or files within the repository, which are used to limit returned
commits.
| |||||||||||
Retrieves the keys of
index properties to load for returned commits. | |||||||||||
Retrieves the primary repository.
| |||||||||||
When retrieving commits between repositories, retrieves the secondary repository.
| |||||||||||
Whether or not the commit history will attempt to follow renames.
| |||||||||||
This method is deprecated.
in 4.5. This return type will change to
boolean in 5.0.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.atlassian.bitbucket.commit.AbstractCommitsRequest
| |||||||||||
From class
java.lang.Object
| |||||||||||
Retrieves commits, which may be identified by branch or tag name or by hash, which should be excluded from the results.
Note: Branch and tag names are always resolved against the primary repository.
Retrieves commits, which may be identified by branch or tag name or by hash, which should be included in the
results. When a commit is both included and excluded, it is excluded.
Note: Branch and tag names are always resolved against the primary repository.
UNLIMITED_MESSAGE_LENGTH to include the full commit message regardless of lengthRetrieves paths, which may identify directories or files within the repository, which are used to limit returned commits. When multiple paths are provided, commits which modify any of the specified paths may be returned.
Retrieves the keys of index properties to load for returned commits.
When retrieving commits between repositories, retrieves the secondary repository. Commits in this
repository may only be identified by hash. Any branch or tag names used will always be resolved
using the primary repository.
Whether or not the commit history will attempt to follow renames. This is only applicable for individual file
paths
true if renames are followed, false otherwise
This method is deprecated.
in 4.5. This return type will change to boolean in 5.0.
null to let the application figure out whether
to do so.