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

minExclusive=0, fractionDigits=2 wrong annotation #38

Open
SZD-48 opened this issue Jun 30, 2015 · 1 comment
Open

minExclusive=0, fractionDigits=2 wrong annotation #38

SZD-48 opened this issue Jun 30, 2015 · 1 comment

Comments

@SZD-48
Copy link

SZD-48 commented Jun 30, 2015

Hi,
for schema

<xs:complexType name="Invoice">
    <xs:sequence>
        <xs:element name="amount">
            <xs:simpleType>
                <xs:restriction base="xs:decimal">
                    <xs:minExclusive value="0"/>
                    <xs:fractionDigits value="2"/>
                </xs:restriction>
            </xs:simpleType>
        </xs:element>
    </xs:sequence>
</xs:complexType>

plugin generates

@NotNull
@DecimalMin("1")
protected BigDecimal amount;

Thanks,
Fedor.

@EPluribusUnum
Copy link

@SZD-48 , I ran into the same issue.
Use : -XJsr303Annotations:JSR_349=true
@DecimalMin(value = "0", inclusive = false) will be generated.

(see JaxbValidationsPlugins.java jsr349 variable)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants