Skip to content

encoding problem with maven-jaxb2-plugin #32

Open
@andersonsoares

Description

@andersonsoares

Hi, iam testing those projects from http://confluence.highsource.org/display/HJ3/Downloads to generate some java files from xsd.

I got it working with maven-hyperjaxb3-plugin, generating UTF-8 files like i wanted, but it didnt with maven-jaxb2-plugin and hyperjaxb3-ejb-plugin . I got encoding issues with those plugins. I tried to set tag into pom.xml but didnt work.

  • Basic project template for Hibernate MAVEN (only that generated utf-8 java files)
  • Purchase order initial sample for Hibernate MAVEN (got encoding issue)
  • Purchase order build with maven-jaxb2-plugin MAVEN (got encoding issue)

Any tips about it?

Also, i realize that the source code generated with those projects are differents.
For example:

//Advogado
<xs:element name="advogado" type="nsS:Pessoa"/>

//Pessoa

<xs:complexType name="Pessoa">
        <xs:annotation>
            <xs:appinfo>
                <hj:entity xmlns:hj="http://hyperjaxb3.jvnet.org/ejb/schemas/customizations">
                    <orm:sequence-generator name="Generator_PESSOA" sequence-name="SEQ_PESSOA" xmlns:orm="http://java.sun.com/xml/ns/persistence/orm"/>
                </hj:entity>
            </xs:appinfo>
        </xs:annotation>
        <xs:sequence>
...

with maven-hyperjaxb3-plugin generates this:

....
@Entity(name = "Advogado")
@Table(name = "ADVOGADO")
@Inheritance(strategy = InheritanceType.JOINED)
public class Advogado
....

with maven-jaxb2-plugin and hyperjaxb3-ejb-plugin generates this:

...
@Entity(name = "Advogado")
@Table(name = "ADVOGADO",schema="selodig")
@Inheritance(strategy = InheritanceType.JOINED)
@SequenceGenerator(name = "Generator_ADVOGADO", sequenceName = "seq_advogado")
public class Advogado
...

so, whats happening?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions