Ok, it works now! The working sample: ----------------------- cut ----------------------- /* orig.namespaces */ <mix = 'http://www.jcp.org/jcr/mix/1.0'> <nt = 'http://www.jcp.org/jcr/nt/1.0'>
/* Project-specific stuff */ <zecms = 'http://www.example.com/zecms/1.0'> [zecms:FragmentType] > 'nt:hierarchyNode', 'mix:referenceable' orderable mixin -zecms:user (string) version mandatory -zecms:ts (date) version mandatory -zecms:rights (string) = 'guest:r', 'admin:rw' version multiple +zecms:data (nt:unstructured) version ----------------------- cut ----------------------- It looks like the parser has some problems... Take care, L. On 5/29/07, Lóránd Somogyi <[EMAIL PROTECTED]> wrote:
Well, yes, that was a bug, but not the one that cause the Exception. The corrected CND is, the line in question is marked with: <<<<<<: ----------------------- cut ----------------------- /* orig.namespaces */ <mix = 'http://www.jcp.org/jcr/mix/1.0'<http://www.jcp.org/jcr/mix/1.0%27> > <nt = 'http://www.jcp.org/jcr/nt/1.0' <http://www.jcp.org/jcr/nt/1.0%27>> /* Project-specific stuff */ <zecms = 'http://www.fusionr.com/zecms/1.0'<http://www.fusionr.com/zecms/1.0%27> > [zecms:FragmentType] > nt:hierarchyNode, mix:referenceable orderable mixin -zecms:user (string) VERSION MANDATORY <<<<<< this is the 10th line -zecms:ts (date) VERSION MANDATORY -zecms:rights (string) = 'guest:r', 'admin:rw' VERSION MULTIPLE +zecms:data (nt:unstructured) VERSION ----------------------- cut ----------------------- Any tips? Thx, L. On 5/25/07, Tako Schotanus <[EMAIL PROTECTED]> wrote: > > I have no idea if this is the actual problem, but it was the first > thing I immediately noticed when looking at your CND: > > 'guest:r', admin:rw' > > Somehow 3 quotes seems wrong and is bound to give problems somewhere. > > Cheers, > -Tako > > On 5/25/07, Lóránd Somogyi <[EMAIL PROTECTED]> wrote: > > Hi, > > > > I have the following CND file: > > > > ----------------- cut ----------------- > > /* orig.namespaces */ > > <mix = 'http://www.jcp.org/jcr/mix/1.0'<http://www.jcp.org/jcr/mix/1.0%27> > > > > <nt = 'http://www.jcp.org/jcr/nt/1.0' > <http://www.jcp.org/jcr/nt/1.0%27>> > > > > /* Project-specific stuff */ > > <zecms = 'http://www.example.com/zecms/1.0'<http://www.example.com/zecms/1.0%27> > > > > > > [zecms:FragmentType] > nt:hierarchyNode, mix:referenceable > > orderable mixin > > -zecms:user (string) VERSION MANDATORY > > -zecms:ts (date) VERSION MANDATORY > > -zecms:rights (string) > > = 'guest:r', admin:rw' > > VERSION MULTIPLE > > +zecms:data (nt:unstructured) VERSION > > ----------------- cut ----------------- > > > > When I try to parse it, with: > > > > ----------------- cut ----------------- > > cndReader = new CompactNodeTypeDefReader(reader , ""); > > ----------------- cut ----------------- > > > > I got the next Exception: > > ----------------- cut ----------------- > > org.apache.jackrabbit.core.nodetype.compact.ParseException: Missing > '[' > > delimiter for beginning of node type name (line 10) > > at org.apache.jackrabbit.core.nodetype.compact.Lexer.fail( > Lexer.java > > :148) > > at > > > org.apache.jackrabbit.core.nodetype.compact.CompactNodeTypeDefReader.doNodeTypeName > > (CompactNodeTypeDefReader.java:252) > > at > > > org.apache.jackrabbit.core.nodetype.compact.CompactNodeTypeDefReader.parse > ( > > CompactNodeTypeDefReader.java:205) > > at > org.apache.jackrabbit.core.nodetype.compact.CompactNodeTypeDefReader > > .<init>(CompactNodeTypeDefReader.java:168) > > at > org.apache.jackrabbit.core.nodetype.compact.CompactNodeTypeDefReader > > .<init>(CompactNodeTypeDefReader.java:153) > > ----------------- cut ----------------- > > > > And just can't figure out what's wrong... :-( > > > > I'm using jackrabbit 1.3 from Maven repository. > > > > Thx, > > L. > > > -- Lóránd Somogyi
-- Lóránd Somogyi
