Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for generic types in tr:adapter #1

Open
virtual-machinist opened this issue Mar 6, 2018 · 0 comments
Open

Support for generic types in tr:adapter #1

virtual-machinist opened this issue Mar 6, 2018 · 0 comments
Assignees

Comments

@virtual-machinist
Copy link

Great plugin. Very helpful when interfacing with SOAP/XML services (that tend to grow more legacy with each passing day, but that's another topic 😄). However there's one feature still missing.
Right now if I write

        <tr:alias property="propertyName" alias="prop">
          <tr:adapter class="com.example.ValueWrapperXmlAdapter"
                      to="java.util.ArrayList&lt;java.lang.String&gt;" />
        </tr:alias>

in my bindings file, I get a non-compiling class with

package foo.bar;
import java.util.ArrayList<java.lang.String>;
...
    @XmlElement(name = "PropertyName")
    @XmlJavaTypeAdapter(ValueWrapperXmlAdapter.class)
    protected String>prop;

I am using the plugin in Gradle together with wsdl2java and jaxb2commons. If I don't specify the generic type everything seems to produce code that compiles, but that means I have to do unsafe casting everywhere.
Any chance to fix this or work around more elegantly?

@dschulten dschulten self-assigned this Mar 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants