Object o = null;
TypeBinding type = element.getType();
if(!type.isSimple())
{
ClassMetaData classMetaData = element.getClassMetaData();
MapEntryMetaData mapEntryMetaData = element.getMapEntryMetaData();
// todo: if addMethod is specified, it's probably some collection field
// but should not be set as a property. Instead, items are added to it using the addMethod
if(classMetaData == null && type.isArrayWrapper() && element.getAddMethodMetaData() == null)
{
if(parent == null)
{
ElementBinding item = type.getArrayItem();
TypeBinding itemType = item.getType();
Class itemCls;
QName itemTypeQName = itemType.getQName();
if(itemTypeQName != null && Constants.NS_XML_SCHEMA.equals(itemTypeQName.getNamespaceURI()))
{
itemCls = SimpleTypeBindings.classForType(itemType.getQName().getLocalPart());
}
else
{
ClassMetaData itemClsMetaData = itemType.getClassMetaData();
String itemClsName = itemClsMetaData == null ? null : itemClsMetaData.getImpl();
itemCls = getClass(itemClsName, item, type.getArrayItemQName());
}
if(itemCls != null)
{