List<RepositoryTreeNode<Ref>> refs = new ArrayList<RepositoryTreeNode<Ref>>();
try {
for (Entry<String, Ref> refEntry : getRefs(repo, RefDatabase.ALL).entrySet()) {
String name=refEntry.getKey();
if (!(name.startsWith(Constants.R_HEADS) || name.startsWith(Constants.R_TAGS)|| name.startsWith(Constants.R_REMOTES)))
refs.add(new AdditionalRefNode(node, repo, refEntry
.getValue()));
}
for (Ref r : repo.getRefDatabase().getAdditionalRefs())
refs.add(new AdditionalRefNode(node, repo, r));
} catch (Exception e) {
return handleException(e, node);
}
return refs.toArray();
}