Program: 64515
Project: 64515
Buggy source:
private void lazyInitialize(){
  if (initialized) {
    return;
  }
synchronized (this) {
    if (initialized) {
      return;
    }
    Descriptor xmlDescriptor=(Descriptor)getDescriptor();
    Iterator mappingIterator=xmlDescriptor.getMappings().iterator();
    Iterator fieldTransformerIterator;
    Mapping xmlMapping;
    AbstractTransformationMapping transformationMapping;
    FieldTransformerNodeValue fieldTransformerNodeValue;
    Object[] nextFieldToTransformer;
    TypeNodeValue typeNodeValue;
    NodeValue mappingNodeValue=null;
    XMLField xmlField;
    while (mappingIterator.hasNext()) {
      xmlMapping=(Mapping)mappingIterator.next();
      if (xmlMapping instanceof InverseReferenceMapping) {
        continue;
      }
      xmlField=(XMLField)xmlMapping.getField();
      if (xmlMapping.isTransformationMapping()) {
        transformationMapping=(AbstractTransformationMapping)xmlMapping;
        addTransformationMapping(transformationMapping);
        fieldTransformerIterator=transformationMapping.getFieldToTransformers().iterator();
        while (fieldTransformerIterator.hasNext()) {
          fieldTransformerNodeValue=new FieldTransformerNodeValue();
          nextFieldToTransformer=(Object[])fieldTransformerIterator.next();
          xmlField=(XMLField)nextFieldToTransformer[0];
          fieldTransformerNodeValue.setXMLField(xmlField);
          fieldTransformerNodeValue.setFieldTransformer((FieldTransformer)nextFieldToTransformer[1]);
          addChild(xmlField.getXPathFragment(),fieldTransformerNodeValue,xmlDescriptor.getNamespaceResolver());
        }
      }
 else {
        if (xmlMapping.isAbstractDirectMapping()) {
          mappingNodeValue=new XMLDirectMappingNodeValue((DirectMapping)xmlMapping);
        }
 else         if (xmlMapping.isAbstractCompositeObjectMapping()) {
          mappingNodeValue=new XMLCompositeObjectMappingNodeValue((CompositeObjectMapping)xmlMapping);
        }
 else         if (xmlMapping.isAbstractCompositeDirectCollectionMapping()) {
          DirectCollectionMapping collectionMapping=(DirectCollectionMapping)xmlMapping;
          mappingNodeValue=new XMLCompositeDirectCollectionMappingNodeValue(collectionMapping);
          if (collectionMapping.getWrapperNullPolicy() != null) {
            addChild(xmlField.getXPathFragment(),new CollectionGroupingElementNodeValue((ContainerValue)mappingNodeValue),xmlDescriptor.getNamespaceResolver());
          }
        }
 else         if (xmlMapping.isAbstractCompositeCollectionMapping()) {
          CompositeCollectionMapping collectionMapping=(CompositeCollectionMapping)xmlMapping;
          mappingNodeValue=new XMLCompositeCollectionMappingNodeValue(collectionMapping);
          if (collectionMapping.getWrapperNullPolicy() != null) {
            addChild(xmlField.getXPathFragment(),new CollectionGroupingElementNodeValue((ContainerValue)mappingNodeValue),xmlDescriptor.getNamespaceResolver());
          }
        }
 else         if (xmlMapping instanceof AnyObjectMapping) {
          mappingNodeValue=new XMLAnyObjectMappingNodeValue((AnyObjectMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof AnyCollectionMapping) {
          mappingNodeValue=new XMLAnyCollectionMappingNodeValue((AnyCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof AnyAttributeMapping) {
          mappingNodeValue=new XMLAnyAttributeMappingNodeValue((AnyAttributeMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof BinaryDataMapping) {
          mappingNodeValue=new XMLBinaryDataMappingNodeValue((BinaryDataMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof BinaryDataCollectionMapping) {
          mappingNodeValue=new XMLBinaryDataCollectionMappingNodeValue((BinaryDataCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof FragmentMapping) {
          mappingNodeValue=new XMLFragmentMappingNodeValue((FragmentMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof FragmentCollectionMapping) {
          mappingNodeValue=new XMLFragmentCollectionMappingNodeValue((FragmentCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof CollectionReferenceMapping) {
          CollectionReferenceMapping xmlColMapping=(CollectionReferenceMapping)xmlMapping;
          List fields=xmlColMapping.getFields();
          XMLField xmlColMappingField=(XMLField)xmlColMapping.getField();
          XPathNode branchNode;
          if (null == xmlColMappingField) {
            if (fields.size() > 1 && !xmlColMapping.usesSingleNode()) {
              addChild(XPathFragment.SELF_FRAGMENT,new XMLCollectionReferenceMappingMarshalNodeValue(xmlColMapping),xmlDescriptor.getNamespaceResolver());
            }
            branchNode=rootXPathNode;
          }
 else {
            branchNode=addChild(((XMLField)xmlColMapping.getField()).getXPathFragment(),new XMLCollectionReferenceMappingMarshalNodeValue(xmlColMapping),xmlDescriptor.getNamespaceResolver());
          }
          int containerIndex=-1;
          for (int i=0, size=fields.size(); i < size; i++) {
            XMLField xmlFld=(XMLField)fields.get(i);
            mappingNodeValue=new XMLCollectionReferenceMappingNodeValue(xmlColMapping,xmlFld);
            if (i == 0) {
              addContainerValue((ContainerValue)mappingNodeValue);
              containerIndex=((ContainerValue)mappingNodeValue).getIndex();
            }
 else {
              ((ContainerValue)mappingNodeValue).setIndex(containerIndex);
            }
            if (mappingNodeValue.isNullCapableValue()) {
              addNullCapableValue((NullCapableValue)mappingNodeValue);
            }
            branchNode.addChild(xmlFld.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ObjectReferenceMapping) {
          ObjectReferenceMapping xmlORMapping=(ObjectReferenceMapping)xmlMapping;
          Iterator fieldIt=xmlORMapping.getFields().iterator();
          while (fieldIt.hasNext()) {
            XMLField xmlFld=(XMLField)fieldIt.next();
            mappingNodeValue=new XMLObjectReferenceMappingNodeValue(xmlORMapping,xmlFld);
            if (mappingNodeValue.isContainerValue()) {
              addContainerValue((ContainerValue)mappingNodeValue);
            }
            if (mappingNodeValue.isNullCapableValue()) {
              addNullCapableValue((NullCapableValue)mappingNodeValue);
            }
            addChild(xmlFld.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ChoiceObjectMapping) {
          ChoiceObjectMapping xmlChoiceMapping=(ChoiceObjectMapping)xmlMapping;
          Iterator fields=xmlChoiceMapping.getChoiceElementMappings().keySet().iterator();
          XMLField firstField=(XMLField)fields.next();
          XMLChoiceObjectMappingNodeValue firstNodeValue=new XMLChoiceObjectMappingNodeValue(xmlChoiceMapping,firstField);
          firstNodeValue.setNullCapableNodeValue(firstNodeValue);
          this.addNullCapableValue(firstNodeValue);
          addChild(firstField.getXPathFragment(),firstNodeValue,xmlDescriptor.getNamespaceResolver());
          while (fields.hasNext()) {
            XMLField next=(XMLField)fields.next();
            XMLChoiceObjectMappingNodeValue nodeValue=new XMLChoiceObjectMappingNodeValue(xmlChoiceMapping,next);
            nodeValue.setNullCapableNodeValue(firstNodeValue);
            addChild(next.getXPathFragment(),nodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ChoiceCollectionMapping) {
          ChoiceCollectionMapping xmlChoiceMapping=(ChoiceCollectionMapping)xmlMapping;
          Iterator<Entry<XMLField,XMLMapping>> fields=xmlChoiceMapping.getChoiceElementMappings().entrySet().iterator();
          Entry<XMLField,XMLMapping> firstEntry=fields.next();
          XMLField firstField=firstEntry.getKey();
          XMLChoiceCollectionMappingUnmarshalNodeValue unmarshalValue=new XMLChoiceCollectionMappingUnmarshalNodeValue(xmlChoiceMapping,firstField);
          XMLChoiceCollectionMappingMarshalNodeValue marshalValue=new XMLChoiceCollectionMappingMarshalNodeValue(xmlChoiceMapping,firstField);
          HashMap<XMLField,NodeValue> fieldToNodeValues=new HashMap<XMLField,NodeValue>();
          unmarshalValue.setContainerNodeValue(unmarshalValue);
          unmarshalValue.setFieldToNodeValues(fieldToNodeValues);
          if (xmlChoiceMapping.isMixedContent() && (xmlChoiceMapping.getMixedContentMapping() == firstEntry.getValue())) {
            unmarshalValue.setIsMixedNodeValue(true);
            marshalValue.setIsMixedNodeValue(true);
          }
          this.addContainerValue(unmarshalValue);
          ((ContainerValue)unmarshalValue.getChoiceElementNodeValue()).setIndex(unmarshalValue.getIndex());
          fieldToNodeValues.put(firstField,unmarshalValue);
          addChild(firstField.getXPathFragment(),unmarshalValue,xmlDescriptor.getNamespaceResolver());
          addChild(firstField.getXPathFragment(),marshalValue,xmlDescriptor.getNamespaceResolver());
          while (fields.hasNext()) {
            Entry<XMLField,XMLMapping> nextEntry=fields.next();
            XMLField nextField=nextEntry.getKey();
            XMLChoiceCollectionMappingUnmarshalNodeValue nodeValue=new XMLChoiceCollectionMappingUnmarshalNodeValue(xmlChoiceMapping,nextField);
            nodeValue.setContainerNodeValue(unmarshalValue);
            nodeValue.setIndex(unmarshalValue.getIndex());
            ((ContainerValue)nodeValue.getChoiceElementNodeValue()).setIndex(unmarshalValue.getIndex());
            addChild(nextField.getXPathFragment(),nodeValue,xmlDescriptor.getNamespaceResolver());
            fieldToNodeValues.put(nextField,nodeValue);
            if (xmlChoiceMapping.isMixedContent() && (xmlChoiceMapping.getMixedContentMapping() == nextEntry.getValue())) {
              nodeValue.setIsMixedNodeValue(true);
            }
          }
          marshalValue.setFieldToNodeValues(fieldToNodeValues);
          continue;
        }
        if (mappingNodeValue.isContainerValue()) {
          addContainerValue((ContainerValue)mappingNodeValue);
        }
        if (mappingNodeValue.isNullCapableValue()) {
          addNullCapableValue((NullCapableValue)mappingNodeValue);
        }
        if (xmlField != null) {
          addChild(xmlField.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
        }
 else {
          addChild(null,mappingNodeValue,xmlDescriptor.getNamespaceResolver());
        }
        if (xmlMapping.isAbstractDirectMapping() && xmlField.isTypedTextField()) {
          XPathFragment nextFragment=xmlField.getXPathFragment();
          StringBuilder typeXPathStringBuilder=new StringBuilder();
          while (nextFragment.getNextFragment() != null) {
            typeXPathStringBuilder.append(nextFragment.getXPath());
            nextFragment=nextFragment.getNextFragment();
          }
          XMLField typeField=new XMLField();
          if (typeXPathStringBuilder.length() > 0) {
            typeXPathStringBuilder.append('/');
          }
          typeField.setXPath(typeXPathStringBuilder.toString() + XMLConstants.ATTRIBUTE + xmlDescriptor.getNonNullNamespaceResolver().resolveNamespaceURI(XMLConstants.SCHEMA_INSTANCE_URL)+ XMLConstants.COLON+ XMLConstants.SCHEMA_TYPE_ATTRIBUTE);
          typeNodeValue=new TypeNodeValue();
          typeNodeValue.setDirectMapping((AbstractDirectMapping)xmlMapping);
          addChild(typeField.getXPathFragment(),typeNodeValue,xmlDescriptor.getNamespaceResolver());
        }
      }
    }
    initialized=true;
  }
}

Fixed version (ground truth):
private void lazyInitialize(){
  if (initialized) {
    return;
  }
synchronized (this) {
    if (initialized) {
      return;
    }
    Descriptor xmlDescriptor=(Descriptor)getDescriptor();
    Iterator mappingIterator=xmlDescriptor.getMappings().iterator();
    Iterator fieldTransformerIterator;
    Mapping xmlMapping;
    AbstractTransformationMapping transformationMapping;
    FieldTransformerNodeValue fieldTransformerNodeValue;
    Object[] nextFieldToTransformer;
    TypeNodeValue typeNodeValue;
    NodeValue mappingNodeValue=null;
    Field xmlField;
    while (mappingIterator.hasNext()) {
      xmlMapping=(Mapping)mappingIterator.next();
      if (xmlMapping instanceof InverseReferenceMapping) {
        continue;
      }
      xmlField=(Field)xmlMapping.getField();
      if (xmlMapping.isTransformationMapping()) {
        transformationMapping=(AbstractTransformationMapping)xmlMapping;
        addTransformationMapping(transformationMapping);
        fieldTransformerIterator=transformationMapping.getFieldToTransformers().iterator();
        while (fieldTransformerIterator.hasNext()) {
          fieldTransformerNodeValue=new FieldTransformerNodeValue();
          nextFieldToTransformer=(Object[])fieldTransformerIterator.next();
          xmlField=(Field)nextFieldToTransformer[0];
          fieldTransformerNodeValue.setXMLField(xmlField);
          fieldTransformerNodeValue.setFieldTransformer((FieldTransformer)nextFieldToTransformer[1]);
          addChild(xmlField.getXPathFragment(),fieldTransformerNodeValue,xmlDescriptor.getNamespaceResolver());
        }
      }
 else {
        if (xmlMapping.isAbstractDirectMapping()) {
          mappingNodeValue=new XMLDirectMappingNodeValue((DirectMapping)xmlMapping);
        }
 else         if (xmlMapping.isAbstractCompositeObjectMapping()) {
          mappingNodeValue=new XMLCompositeObjectMappingNodeValue((CompositeObjectMapping)xmlMapping);
        }
 else         if (xmlMapping.isAbstractCompositeDirectCollectionMapping()) {
          DirectCollectionMapping collectionMapping=(DirectCollectionMapping)xmlMapping;
          mappingNodeValue=new XMLCompositeDirectCollectionMappingNodeValue(collectionMapping);
          if (collectionMapping.getWrapperNullPolicy() != null) {
            addChild(xmlField.getXPathFragment(),new CollectionGroupingElementNodeValue((ContainerValue)mappingNodeValue),xmlDescriptor.getNamespaceResolver());
          }
        }
 else         if (xmlMapping.isAbstractCompositeCollectionMapping()) {
          CompositeCollectionMapping collectionMapping=(CompositeCollectionMapping)xmlMapping;
          mappingNodeValue=new XMLCompositeCollectionMappingNodeValue(collectionMapping);
          if (collectionMapping.getWrapperNullPolicy() != null) {
            addChild(xmlField.getXPathFragment(),new CollectionGroupingElementNodeValue((ContainerValue)mappingNodeValue),xmlDescriptor.getNamespaceResolver());
          }
        }
 else         if (xmlMapping instanceof AnyObjectMapping) {
          mappingNodeValue=new XMLAnyObjectMappingNodeValue((AnyObjectMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof AnyCollectionMapping) {
          mappingNodeValue=new XMLAnyCollectionMappingNodeValue((AnyCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof AnyAttributeMapping) {
          mappingNodeValue=new XMLAnyAttributeMappingNodeValue((AnyAttributeMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof BinaryDataMapping) {
          mappingNodeValue=new XMLBinaryDataMappingNodeValue((BinaryDataMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof BinaryDataCollectionMapping) {
          mappingNodeValue=new XMLBinaryDataCollectionMappingNodeValue((BinaryDataCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof FragmentMapping) {
          mappingNodeValue=new XMLFragmentMappingNodeValue((FragmentMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof FragmentCollectionMapping) {
          mappingNodeValue=new XMLFragmentCollectionMappingNodeValue((FragmentCollectionMapping)xmlMapping);
        }
 else         if (xmlMapping instanceof CollectionReferenceMapping) {
          CollectionReferenceMapping xmlColMapping=(CollectionReferenceMapping)xmlMapping;
          List fields=xmlColMapping.getFields();
          Field xmlColMappingField=(Field)xmlColMapping.getField();
          XPathNode branchNode;
          if (null == xmlColMappingField) {
            if (fields.size() > 1 && !xmlColMapping.usesSingleNode()) {
              addChild(XPathFragment.SELF_FRAGMENT,new XMLCollectionReferenceMappingMarshalNodeValue(xmlColMapping),xmlDescriptor.getNamespaceResolver());
            }
            branchNode=rootXPathNode;
          }
 else {
            branchNode=addChild(((Field)xmlColMapping.getField()).getXPathFragment(),new XMLCollectionReferenceMappingMarshalNodeValue(xmlColMapping),xmlDescriptor.getNamespaceResolver());
          }
          int containerIndex=-1;
          for (int i=0, size=fields.size(); i < size; i++) {
            Field xmlFld=(Field)fields.get(i);
            mappingNodeValue=new XMLCollectionReferenceMappingNodeValue(xmlColMapping,xmlFld);
            if (i == 0) {
              addContainerValue((ContainerValue)mappingNodeValue);
              containerIndex=((ContainerValue)mappingNodeValue).getIndex();
            }
 else {
              ((ContainerValue)mappingNodeValue).setIndex(containerIndex);
            }
            if (mappingNodeValue.isNullCapableValue()) {
              addNullCapableValue((NullCapableValue)mappingNodeValue);
            }
            branchNode.addChild(xmlFld.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ObjectReferenceMapping) {
          ObjectReferenceMapping xmlORMapping=(ObjectReferenceMapping)xmlMapping;
          Iterator fieldIt=xmlORMapping.getFields().iterator();
          while (fieldIt.hasNext()) {
            Field xmlFld=(Field)fieldIt.next();
            mappingNodeValue=new XMLObjectReferenceMappingNodeValue(xmlORMapping,xmlFld);
            if (mappingNodeValue.isContainerValue()) {
              addContainerValue((ContainerValue)mappingNodeValue);
            }
            if (mappingNodeValue.isNullCapableValue()) {
              addNullCapableValue((NullCapableValue)mappingNodeValue);
            }
            addChild(xmlFld.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ChoiceObjectMapping) {
          ChoiceObjectMapping xmlChoiceMapping=(ChoiceObjectMapping)xmlMapping;
          Iterator fields=xmlChoiceMapping.getChoiceElementMappings().keySet().iterator();
          Field firstField=(Field)fields.next();
          XMLChoiceObjectMappingNodeValue firstNodeValue=new XMLChoiceObjectMappingNodeValue(xmlChoiceMapping,firstField);
          firstNodeValue.setNullCapableNodeValue(firstNodeValue);
          this.addNullCapableValue(firstNodeValue);
          addChild(firstField.getXPathFragment(),firstNodeValue,xmlDescriptor.getNamespaceResolver());
          while (fields.hasNext()) {
            Field next=(Field)fields.next();
            XMLChoiceObjectMappingNodeValue nodeValue=new XMLChoiceObjectMappingNodeValue(xmlChoiceMapping,next);
            nodeValue.setNullCapableNodeValue(firstNodeValue);
            addChild(next.getXPathFragment(),nodeValue,xmlDescriptor.getNamespaceResolver());
          }
          continue;
        }
 else         if (xmlMapping instanceof ChoiceCollectionMapping) {
          ChoiceCollectionMapping xmlChoiceMapping=(ChoiceCollectionMapping)xmlMapping;
          Iterator<Entry<Field,XMLMapping>> fields=xmlChoiceMapping.getChoiceElementMappings().entrySet().iterator();
          Entry<Field,XMLMapping> firstEntry=fields.next();
          Field firstField=firstEntry.getKey();
          XMLChoiceCollectionMappingUnmarshalNodeValue unmarshalValue=new XMLChoiceCollectionMappingUnmarshalNodeValue(xmlChoiceMapping,firstField);
          XMLChoiceCollectionMappingMarshalNodeValue marshalValue=new XMLChoiceCollectionMappingMarshalNodeValue(xmlChoiceMapping,firstField);
          HashMap<Field,NodeValue> fieldToNodeValues=new HashMap<Field,NodeValue>();
          unmarshalValue.setContainerNodeValue(unmarshalValue);
          unmarshalValue.setFieldToNodeValues(fieldToNodeValues);
          if (xmlChoiceMapping.isMixedContent() && (xmlChoiceMapping.getMixedContentMapping() == firstEntry.getValue())) {
            unmarshalValue.setIsMixedNodeValue(true);
            marshalValue.setIsMixedNodeValue(true);
          }
          this.addContainerValue(unmarshalValue);
          ((ContainerValue)unmarshalValue.getChoiceElementNodeValue()).setIndex(unmarshalValue.getIndex());
          fieldToNodeValues.put(firstField,unmarshalValue);
          addChild(firstField.getXPathFragment(),unmarshalValue,xmlDescriptor.getNamespaceResolver());
          addChild(firstField.getXPathFragment(),marshalValue,xmlDescriptor.getNamespaceResolver());
          while (fields.hasNext()) {
            Entry<Field,XMLMapping> nextEntry=fields.next();
            Field nextField=nextEntry.getKey();
            XMLChoiceCollectionMappingUnmarshalNodeValue nodeValue=new XMLChoiceCollectionMappingUnmarshalNodeValue(xmlChoiceMapping,nextField);
            nodeValue.setContainerNodeValue(unmarshalValue);
            nodeValue.setIndex(unmarshalValue.getIndex());
            ((ContainerValue)nodeValue.getChoiceElementNodeValue()).setIndex(unmarshalValue.getIndex());
            addChild(nextField.getXPathFragment(),nodeValue,xmlDescriptor.getNamespaceResolver());
            fieldToNodeValues.put(nextField,nodeValue);
            if (xmlChoiceMapping.isMixedContent() && (xmlChoiceMapping.getMixedContentMapping() == nextEntry.getValue())) {
              nodeValue.setIsMixedNodeValue(true);
            }
          }
          marshalValue.setFieldToNodeValues(fieldToNodeValues);
          continue;
        }
        if (mappingNodeValue.isContainerValue()) {
          addContainerValue((ContainerValue)mappingNodeValue);
        }
        if (mappingNodeValue.isNullCapableValue()) {
          addNullCapableValue((NullCapableValue)mappingNodeValue);
        }
        if (xmlField != null) {
          addChild(xmlField.getXPathFragment(),mappingNodeValue,xmlDescriptor.getNamespaceResolver());
        }
 else {
          addChild(null,mappingNodeValue,xmlDescriptor.getNamespaceResolver());
        }
        if (xmlMapping.isAbstractDirectMapping() && xmlField.isTypedTextField()) {
          XPathFragment nextFragment=xmlField.getXPathFragment();
          StringBuilder typeXPathStringBuilder=new StringBuilder();
          while (nextFragment.getNextFragment() != null) {
            typeXPathStringBuilder.append(nextFragment.getXPath());
            nextFragment=nextFragment.getNextFragment();
          }
          Field typeField=new XMLField();
          if (typeXPathStringBuilder.length() > 0) {
            typeXPathStringBuilder.append('/');
          }
          typeField.setXPath(typeXPathStringBuilder.toString() + XMLConstants.ATTRIBUTE + xmlDescriptor.getNonNullNamespaceResolver().resolveNamespaceURI(XMLConstants.SCHEMA_INSTANCE_URL)+ XMLConstants.COLON+ XMLConstants.SCHEMA_TYPE_ATTRIBUTE);
          typeNodeValue=new TypeNodeValue();
          typeNodeValue.setDirectMapping((AbstractDirectMapping)xmlMapping);
          addChild(typeField.getXPathFragment(),typeNodeValue,xmlDescriptor.getNamespaceResolver());
        }
      }
    }
    initialized=true;
  }
}