Hotfix LinkageProcessor with generics
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
yoyosource 2022-12-07 22:33:37 +01:00
Ursprung 746ae701d8
Commit 441661a8f5

Datei anzeigen

@ -292,6 +292,7 @@ public class LinkageProcessor extends AbstractProcessor {
private LinkageType resolveSingle(TypeMirror typeMirror) { private LinkageType resolveSingle(TypeMirror typeMirror) {
String qualifier = typeMirror.toString(); String qualifier = typeMirror.toString();
if (qualifier.contains("<")) qualifier = qualifier.substring(0, qualifier.indexOf('<'));
qualifier = qualifier.substring(qualifier.lastIndexOf('.') + 1); qualifier = qualifier.substring(qualifier.lastIndexOf('.') + 1);
try { try {
return (LinkageType) Class.forName("de.steamwar.linkage.types." + qualifier + "_" + context.name()).getDeclaredConstructor().newInstance(); return (LinkageType) Class.forName("de.steamwar.linkage.types." + qualifier + "_" + context.name()).getDeclaredConstructor().newInstance();