Class BranchesCommandBuilder

java.lang.Object
sonia.scm.repository.api.BranchesCommandBuilder

public final class BranchesCommandBuilder extends Object
The branches command list all repository branches.

Samples:

Return all branches of a repository:

 BranchesCommandBuilder branchesCommand = repositoryService.getBranchesCommand();
 Branches branches = tagsCommand.getBranches();
 
Since:
1.18
  • Method Details

    • getBranches

      public Branches getBranches() throws IOException
      Returns all branches from the repository.
      Returns:
      branches from the repository
      Throws:
      IOException
    • setDisableCache

      public BranchesCommandBuilder setDisableCache(boolean disableCache)
      Disables the cache for tags. This means that every Branch is directly retrieved from the Repository. Note: Disabling the cache cost a lot of performance and could be much slower.
      Parameters:
      disableCache - true to disable the cache
      Returns:
      this