mirror of
https://github.com/zaaarf/lillero.git
synced 2024-11-21 15:04:50 +01:00
fix: broken composition of fully qualified name in TypeProxy
This commit is contained in:
parent
ac4ce489b7
commit
ab7fbd3f6e
2 changed files with 5 additions and 5 deletions
|
@ -37,10 +37,10 @@ public abstract class QualifiableProxy extends AbstractProxy {
|
|||
* @return the parent, or null if the parent was the root element
|
||||
*/
|
||||
protected static String extractParentFromFQN(String fqn) {
|
||||
String lastSeparator = fqn.contains("$") ? "\\$" : "\\.";
|
||||
String[] split = fqn.split(lastSeparator);
|
||||
if(split.length == 1) return null;
|
||||
return fqn.substring(0, split[split.length - 1].length() - 1);
|
||||
String lastSeparator = fqn.contains("$") ? "$" : ".";
|
||||
int pos = fqn.lastIndexOf(lastSeparator);
|
||||
if(pos == -1) return null;
|
||||
return fqn.substring(0, pos);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -29,7 +29,7 @@ public class TypeProxy extends QualifiableProxy {
|
|||
* @param primitive whether the proxy is a primitive
|
||||
*/
|
||||
protected TypeProxy(String name, String descriptor, int modifiers, String parent, boolean primitive) {
|
||||
super(descriptor, modifiers, PackageProxy.from(parent), String.format("%s.%s", name, parent), ProxyType.TYPE);
|
||||
super(descriptor, modifiers, PackageProxy.from(parent), String.format("%s.%s", parent, name), ProxyType.TYPE);
|
||||
this.primitive = primitive;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue