On 25.01.2013, at 16:16, Shah.Abhishek <[email protected]> wrote:

> I *need to* create a Custom Node type using the NodeTypeManager and other
> api available in Jackrabbit 2.4.2. I can successfully create a custom node
> type but am unable to add ChildNodeDefinitions to that node type. 

The CND format importer code might help:

http://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/commons/cnd/CompactNodeTypeDefReader.java

Have a look at the places where Lexer.CHILD_NODE_DEFINITION is used and at the 
method doChildNodeDefinition(). It uses AbstractNodeTypeDefinitionBuilder(s) 
that come from TemplateBuilderFactory.java, but under the hood it's working 
with NodeTypeTemplate.

HTH,
Alex

Reply via email to