code: public NodeDefinitionData[] readNodeDefinitions(NodeData nodeData) throws NodeTypeReadException, RepositoryException
     {
        InternalQName name = null;
        List<NodeDefinitionData> nodeDefinitionDataList;
  
        List<NodeData> childDefinitions = dataManager.getChildNodesData(nodeData);
  
        if (childDefinitions.size() > 0)
           name = readMandatoryName(nodeData, null, Constants.JCR_NODETYPENAME);
        else
           return new NodeDefinitionData[0];
  
        nodeDefinitionDataList = new ArrayList<NodeDefinitionData>();
        for (NodeData childDefinition : childDefinitions)
        {
           if (Constants.NT_CHILDNODEDEFINITION.equals(childDefinition.getPrimaryTypeName()))
           {
              nodeDefinitionDataList.add(nodeDefinitionAccessProvider.read(childDefinition, name));
           }
        }
  
        return nodeDefinitionDataList.toArray(new NodeDefinitionData[nodeDefinitionDataList.size()]);
     }
docs: Read node NodeDefinitionData[]  of node type
  @param nodeData
  @return
  @throws RepositoryException
  @throws NodeTypeReadException
  @throws RepositoryException