Community
Participate
Working Groups
Hello, The isTotalDigitsFacetSupported(org.eclipse.xsd.XSDSimpleTypeDefinition) method of org.eclipse.wst.sse.sieditor.model.utils.SimpleTypeFacetsUtils class returns true for the rootType int but the return value should be false. The valid facets for int returned by the Eclipse EMF model also include totalDigits and fractionDigits which are not supported for int type. Thanks, Noopur Gupta
Hi Noopur, The XSDSimpleTypeDefinition#getValidFacets() method returns the list: [totalDigits, fractionDigits, pattern, whiteSpace, enumeration, maxInclusive, maxExclusive, minInclusive, minExclusive]. We are currently checking if the valid facets list contains the XSDConstants.TOTALDIGITS_ELEMENT_TAG facet. According to the XML Schema specification (http://www.w3.org/TR/xmlschema-2/#int), the fractionDigits facet is allowed, but it's value is restricted to 0. "int" is the derived type of "long" which is the derived type of "integer". The restriction on the fractionDigits is described in http://www.w3.org/TR/xmlschema-2/#integer. If you try to change the value of the fractionDigits facets, a live validation message is shown on the UI control - to show the described restriction. I'm currently unable to find a restrinction on the totalDigits facet. Could you please point me to such a restriction in the XML Schema specification? Since the user can edit the value of the fractionDigits facet through the source, we need to show it in the UI part. Regards, Stanislav
Hi Colleagues, I'm updating the status of this bugzilla since the current one (resolved/invalid) is not correct. The status should have been closed/worksforme. Regards, Stanislav