I want to discern multiple repositories in a Plan.
A ResultsSummary has multiple List<RepositoryChangeset> accordingly to the repositories in a Plan.
To know which RepositoryChangeset is related to which repository, I guess repositoryChangeset.getRepositoryDefinition().getName() is the only way.
It returns like 'Subversion Web', 'Subversion Repository' and so on.
When the repository is Subversion, the repository name becomes 'Subversion' + ' ' + '[Repository Root Path Name with the first letter upper-cased]'.
Is this right?
Hmm, how about RepositoryChangeset.getRepositoryDefinition().getId() and use it to get the repository using
PlanHeleper.getRepositoryDefinitionMap() ? You'll get a RepoDef and you can call getRepository on it.
The repositories can be renamed, so you shouldn't rely on naming. If you want to identify a repository, you should use getId instead of getName.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry for my some misunderstandins.
I want to know which RepositoryChangeset obtained by ResultsSummary#getRepositoryChangesets()
is related to which Repository obtained by PlanHelper.getRepositories(getPlan()).
The repositoryChangeset.getRepositoryDefinition().getId() is good, but on the other hand SvnRepository seems not to have getId().
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.