code: public void update(List<NodeTypeData> nodeTypes, UpdateNodeTypeObserver observer) throws RepositoryException
     {
  
        PlainChangesLog changesLog = new PlainChangesLogImpl();
  
        for (NodeTypeData nodeTypeData : nodeTypes)
        {
  
           if (observer != null)
           {
              if (observer.shouldSkip(nodeTypeData, changesLog))
              {
                 continue;
              }
              observer.beforeUpdate(nodeTypeData, changesLog);
           }
           if (!validatate())
           {
              continue;
           }
           // remove first
           NodeData removeNodeTypeData =
              (NodeData)dataManager.getItemData(nodeTypeStorageRoot, new QPathEntry(nodeTypeData.getName(), 1),
                 ItemType.NODE);
           if (removeNodeTypeData != null)
           {
              ItemDataRemoveVisitor removeVisitor =
                 new ItemDataRemoveVisitor(dataManager, nodeTypeStorageRoot.getQPath());
              removeNodeTypeData.accept(removeVisitor);
  
              changesLog.addAll(removeVisitor.getRemovedStates());
           }
           // add
           definitionAccessProvider.write(changesLog, nodeTypeStorageRoot, nodeTypeData);
           if (observer != null)
           {
              observer.afterUpdate(nodeTypeData, changesLog);
           }
        }
        //made changes if needed
        if (changesLog.getSize() > 0)
        {
           dataManager.save(new TransactionChangesLog(changesLog));
        }
     }
docs: {@inheritDoc}