jackrabbit-oak-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Dürig <mdue...@apache.org>
Subject Re: svn commit: r1416949 - in /jackrabbit/oak/trunk: oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/identifier/ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/nodetype/ oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/ oak...
Date Tue, 04 Dec 2012 15:15:40 GMT


On 4.12.12 14:12, angela@apache.org wrote:
>       /**
> -     * FIXME in contrast what the method name implies this method returns the transitive
closure of the super types
> -     * TODO clarify contract, what is the difference between this method and NodeType.getSuperTypes()
>        * Calculates and returns all effective node types of the given tree.
>        *
>        * @param tree
>        * @return all node types of the given tree
> -     * @throws RepositoryException if the type information can not be accessed
> +     * @throws RepositoryException if the type information can not be accessed,
> +     * @see <a href="http://www.jcp.org/en/jsr/detail?id=283">JCR 2.0 Specification,
> +     * Section</a> for the definition of the effective node type.
>        */
>       Iterable<NodeType> getEffectiveNodeTypes(Tree tree) throws RepositoryException;

I don't think the fixme is addressed with this change. According to the 
cited section in the spec. a node has *an* effective node type. How come 
this method returns an iterator? Also the semantics of subtyping 
( is not adhered to.

I know that the return value of this method is *used* to do effective 
node type calculations and I am not opposed to that. However, we should 
then change the names of this method (and its sister) to better reflect 
what it actually does.


View raw message