jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicolas Dufour" <nrduf...@gmail.com>
Subject New nodeTypes and RMI
Date Wed, 07 Feb 2007 20:05:42 GMT
Hi

I'm trying to register node types i have written in cnd to a JCR repository
on RMI.

I have trouble to find any documentation about the jackrabbit-jcr-rmi jar.

Do I have to use the class ClientJackrabbitNodeTypeManager and give it a
filename knowing that this piece of code give me an exception :

        // Read in the CND file
        FileInputStream fis = new FileInputStream(cndFileName);

        ClientJackrabbitNodeTypeManager ntmgr
=(ClientJackrabbitNodeTypeManager) ws.getNodeTypeManager();

        ntmgr.registerNodeTypes(fis, "toto");

The exception :

java.lang.ClassCastException:
org.apache.jackrabbit.rmi.client.ClientNodeTypeManager cannot be cast to
org.apache.jackrabbit.rmi.jackrabbit.ClientJackrabbitNodeTypeManager
    at tips.jcr.NodeTypeRegister.registerCustomNodeTypes(
NodeTypeRegister.java:55)
    at tips.jcr.NodeTypeRegister.registerCustomNodeTypesInDefault(
NodeTypeRegister.java:47)
    at tips.jcr.NodeTypeRegister.main(NodeTypeRegister.java:105)

Thank you

Nicolas Dufour

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message