]
Yusuf Iskenderoglu updated ROASTER-49:
--------------------------------------
Issue Type: Bug (was: Feature Request)
Impossible to create a field of type HashMap<Class<?>,
Object>
--------------------------------------------------------------
Key: ROASTER-49
URL:
https://issues.jboss.org/browse/ROASTER-49
Project: Roaster
Issue Type: Bug
Reporter: Yusuf Iskenderoglu
Roaster does not like question-mark-operator:
{code}
to.addField()
.setFinal(true)
.setName("AS_MAP")
.setPrivate()
.setStatic(true)
.setType("HashMap<Class<?>, Object>")
.setLiteralInitializer("new HashMap<>();");
{code}
cannot be used:
{verbatim}
Exception in thread "main" java.lang.IllegalArgumentException: Cannot parse
type parameter ?
at org.jboss.forge.roaster.model.util.Types.toSimpleName(Types.java:196)
at org.jboss.forge.roaster.model.util.Types.toSimpleName(Types.java:198)
at org.jboss.forge.roaster.model.impl.FieldImpl.setType(FieldImpl.java:334)
:support:main:roastJavaExecTask FAILED
{verbatim}