I have the namespace at the top of my CND file, but I still get the error
message.

Ted

2006/11/10, Stefan Guggisberg <[EMAIL PROTECTED]>:

On 11/10/06, Ted Roeloffzen <[EMAIL PROTECTED]> wrote:
> First i want to register the namespace, then i want to register some
custom
> nodetypes.
>
> JCRSessionManager.getJCRSession
().getWorkspace().getNamespaceRegistry().registerNamespace("kronos",
> "http://kronos.com";);
> JCRSessionManager.insertNodeTypeDefinition("NodeType.cnd");

did you add the namespace declaration, i.e.  <kronos="http://kronos.com";>,
at
the top of your .cnd file? for the cnd format see

http://jackrabbit.apache.org/api-1/org/apache/jackrabbit/core/nodetype/compact/CompactNodeTypeDefReader.html

btw: if you're using
o.a.j.api.JackrabbitNodeTypeManager#registerNodeTypes(InputStream,
String) you don't have to manually register the namespaces declared in
your cnd file.

cheers
stefan

>
> Ted
>
> 2006/11/10, Stefan Guggisberg <[EMAIL PROTECTED]>:
> >
> > On 11/10/06, Ted Roeloffzen <[EMAIL PROTECTED]> wrote:
> > > I registered the namespace, but i still get this error.
> > >
> > > javax.jcr.NamespaceException: http://kronos.com: is not a registered
> > > namespace uri.
> >
> > you'll have to be a bit more specific than that. what exactly are you
> > trying
> > to do?
> >
> > cheers
> > stefan
> >
> > >
> > > Ted
> > >
> > > 2006/11/10, Ted Roeloffzen <[EMAIL PROTECTED]>:
> > > >
> > > > Okay thank you very much.
> > > >
> > > > Ted
> > > >
> > > > 2006/11/10, Tobias Bocanegra <[EMAIL PROTECTED]>:
> > > > >
> > > > > take a look at:
> > > > >
> > > > >
> > > > >
> >
http://www.day.com/maven/jsr170/javadocs/jcr-1.0/javax/jcr/NamespaceRegistry.html
> > > > >
> > > > > regards, toby
> > > > >
> > > > > On 11/10/06, Ted Roeloffzen <[EMAIL PROTECTED]> wrote:
> > > > > > How do I register a new namespace with JackRabbit? Do i have
to
> > > > > include it
> > > > > > manually in the properties file or is there another way. I
wasn't
> > able
> > > > > to
> > > > > > find any examples or how to's on the internet.
> > > > > >
> > > > > > Ted
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > -----------------------------------------<
[EMAIL PROTECTED]>---
> > > > > Tobias Bocanegra, Day Management AG, Barfuesserplatz 6, CH -
4001
> > Basel
> > > > > T +41 61 226 98 98, F +41 61 226 98 97
> > > > > -----------------------------------------------<
http://www.day.com>---
> > > > >
> > > >
> > > >
> > >
> > >
> >
>
>

Reply via email to