- Restriction restriction = simpleType.getRestriction();\r
- if (restriction == null)\r
- throw new RuntimeException("Cannot resolve type for Attribute " + attrName + " -> " + primitiveType.getLocalPart()+ ", SimpleType restriction is unset");\r
- QName base = restriction.getBase();\r
- \r
- \r
- //String binding = getBindingFromPrimitiveType(base);\r
- TypeEntry binding = getTypeEntry(base);\r
- writeAttribute(fw, attrName, relationName, binding, isReference);\r
+ org.w3._2001.xmlschema.List list = simpleType.getList();\r
+ if (list != null) {\r
+ TypeEntry binding = getTypeEntry(new QName(SCHEMA_NS, "string"));\r
+ writeAttribute(fw, attrName, relationName, binding, isReference);\r
+ } else {\r
+ Restriction restriction = simpleType.getRestriction();\r
+ if (restriction == null)\r
+ throw new RuntimeException("Cannot resolve type for Attribute " + attrName + " -> " + primitiveType.getLocalPart()+ ", SimpleType restriction is unset");\r
+ QName base = restriction.getBase();\r
+ \r
+ \r
+ //String binding = getBindingFromPrimitiveType(base);\r
+ TypeEntry binding = getTypeEntry(base);\r
+ writeAttribute(fw, attrName, relationName, binding, isReference);\r
+ }\r