You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by Stefan Guggisberg <st...@gmail.com> on 2007/08/02 12:11:01 UTC

Re: Inheritance of "orderable" attribute for node types

hi christoph

On 7/31/07, Christoph Kiehl <ch...@sulu3000.de> wrote:
> Hi,
>
> we just discovered, that the "orderable" attribute of node types is not
> inherited from supertypes. NodeTypeImpl.hasOrderableChildNodes() just calls
> NodeTypeDef.hasOrderableChildNodes() instead of using the EffectiveNodeType to
> determine if a node type allows orderable child nodes.
> The specification does not define how this should be handled (6.7.8 Inheritance
> Among Node Types), but was there any reason not to use EffectiveNodeType?

the jsr 170 spec and the current public-review-draft of the jsr 283 spec (4.7.7)
leave it up to the implementation whether e.g. the orderable child nodes setting
is inherited from supertypes.

inheritance semantics, especially with multiple inhertitance, are
non-trivial at best
and up to a certain degree arbitrary.

e.g. assume the following:

[A]
  - foo (string) primary mandatory
[B]
  - bar (string) primary mandatory

[C] > A, B

now given a node of type C, which property (foo/bar) is the primary item?

jackrabbit therefore, in compliance with the spec, doesn't support inheritance
of node type attributes.

cheers
stefan

>
> Cheers,
> Christoph
>
>

Re: Inheritance of "orderable" attribute for node types

Posted by Christoph Kiehl <ch...@sulu3000.de>.
Stefan Guggisberg wrote:

>> we just discovered, that the "orderable" attribute of node types is not
>> inherited from supertypes. NodeTypeImpl.hasOrderableChildNodes() just calls
>> NodeTypeDef.hasOrderableChildNodes() instead of using the EffectiveNodeType to
>> determine if a node type allows orderable child nodes.
>> The specification does not define how this should be handled (6.7.8 Inheritance
>> Among Node Types), but was there any reason not to use EffectiveNodeType?
> 

[..]

> inheritance semantics, especially with multiple inhertitance, are
> non-trivial at best
> and up to a certain degree arbitrary.

[..]

> jackrabbit therefore, in compliance with the spec, doesn't support inheritance
> of node type attributes.

Ok. Thanks for the clarification and reasoning.

Cheers,
Christoph