{
upperBound = xsdLengthFacet.getValue();
}
else
{
XSDMaxLengthFacet xsdMaxLengthFacet = attributeTypeDefinition.getEffectiveMaxLengthFacet();
if (xsdMaxLengthFacet != null)
{
upperBound = xsdMaxLengthFacet.getValue();
}
else
{
upperBound = -1;
}
}
}
EClassifier referenceClassifier = getEClassifier(referenceType);
EStructuralFeature result =
createFeature
(eClass,
name,
referenceClassifier,
xsdComponent,
lowerBound,
upperBound);
initialize(result, xsdAttributeDeclaration, xsdComponent);
return result;
}
else
{
boolean isMany =
attributeTypeDefinition.getVariety() == XSDVariety.LIST_LITERAL &&
xsdComponent instanceof XSDAttributeUse &&
"true".equals(getEcoreAttribute(xsdComponent, "many"));
if (isMany)
{
EDataType eDataType = getEDataType(attributeTypeDefinition.getItemTypeDefinition());
XSDLengthFacet xsdLengthFacet = attributeTypeDefinition.getEffectiveLengthFacet();
int lowerBound = isRequired ? 1 : 0;
int upperBound = -1;
if (isRequired)
{
if (xsdLengthFacet != null)
{
lowerBound = xsdLengthFacet.getValue();
}
else
{
XSDMinLengthFacet xsdMinLengthFacet = attributeTypeDefinition.getEffectiveMinLengthFacet();
if (xsdMinLengthFacet != null)
{
lowerBound = xsdMinLengthFacet.getValue();
}
}
}
if (xsdLengthFacet != null)
{
upperBound = xsdLengthFacet.getValue();
}
else
{
XSDMaxLengthFacet xsdMaxLengthFacet = attributeTypeDefinition.getEffectiveMaxLengthFacet();
if (xsdMaxLengthFacet != null)
{
upperBound = xsdMaxLengthFacet.getValue();
}
}
EStructuralFeature result =
createFeature
(eClass,