Found a way to solve this issue. What I did was adding a "&o=MESSAGES" tag to the query to retrieve the full change history list where the revert message gives you the target commit ID.
I then transfer the Collection<> that is returned into a list so I can easily access all the messages.
Collection<ChangeMessageInfo> messageColl = gerritClient.changes().query("commit:<commitID>&o=MESSAGES").get().get(0).messages;
final List<ChangeMessageInfo> messageList = new ArrayList<>(messageColl);
The revert message is usually the last entry of the change history log.
List of tags that can be used in a similar manner can be found here. You need to scroll down a bit to find the tags.
UPDATE:
Found an even more effecient way of finding the reverted commits.
With the code below you are able to retrieve the body message below the subject on Gerrit which in turn enables the possibility to query the commit ID that is presented in that field.
List<String> revertedCommits = new ArrayList<>();
revertedCommits.add(<commitID>);
String revertedCommit = "unknown";
Map<String, RevisionInfo> revisionInfo = gerritClient.changes().query("commit:" + revertedCommits.get(revertedCommits.size() - 1) + "&o=CURRENT_REVISION&o=COMMIT_FOOTERS").get().get(0).revisions;
Pattern p = Pattern.compile(Pattern.quote("This reverts commit ") + "(.*?)" + Pattern.quote("."));
Matcher m = p.matcher(revisionInfo.values().iterator().next().commitWithFooters);
while (m.find()) {
revertedCommit = m.group(1);
}
This can then be iterated through to find all the reverts connected to the first commit.
Note that I use the "&o=CURRENT_REVISION" and "&o=COMMIT_FOOTERS" tags in the query to access this information. Without these tags, you only get an empty array.