code: protected Document createDocument(NodeData node, NamespaceMappings nsMappings,
                                        IndexFormatVersion indexFormatVersion, boolean loadAllProperties)
        throws RepositoryException
     {
        return createDocument(new NodeDataIndexing(node), nsMappings, indexFormatVersion, loadAllProperties, null);
     }
docs: Creates a lucene <code>Document</code> for a node state using the
  namespace mappings <code>nsMappings</code>.
  
  @param node
  the node state to index.
  @param nsMappings
  the namespace mappings of the search index.
  @param indexFormatVersion
  the index format version that should be used to index the
  passed node state.
  @param loadAllProperties
  Indicates whether all the properties should be loaded using the method
  {@link ItemDataConsumer#getChildPropertiesData(org.exoplatform.services.jcr.datamodel.NodeData)}
  @return a lucene <code>Document</code> that contains all properties of
  <code>node</code>.
  @throws RepositoryException
  if an error occurs while indexing the <code>node</code>.