You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Jukka Zitting (JIRA)" <ji...@apache.org> on 2013/04/10 10:44:16 UTC
[jira] [Resolved] (OAK-765) AbstractNodeState#getChildNode returns
null despite @Nonnull return value
[ https://issues.apache.org/jira/browse/OAK-765?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jukka Zitting resolved OAK-765.
-------------------------------
Resolution: Fixed
Fix Version/s: 0.7
Assignee: Jukka Zitting
Fixed in http://svn.apache.org/r1466379 by simply dropping the method. None of the subclasses use this default getChildNode() implementation, and fixing it with EmptyNodeState.MISSING_NODE would have been a bit troublesome due to the spi package boundary.
> AbstractNodeState#getChildNode returns null despite @Nonnull return value
> -------------------------------------------------------------------------
>
> Key: OAK-765
> URL: https://issues.apache.org/jira/browse/OAK-765
> Project: Jackrabbit Oak
> Issue Type: Bug
> Components: core
> Reporter: angela
> Assignee: Jukka Zitting
> Fix For: 0.7
>
>
> the implementation of AbstractNodeState#getChildNode looks as follows:
> {code}
> @Override
> public NodeState getChildNode(String name) {
> checkNotNull(name);
> for (ChildNodeEntry entry : getChildNodeEntries()) {
> if (name.equals(entry.getName())) {
> return entry.getNodeState();
> }
> }
> return null;
> }
> {code}
> this violates the contract defined by NodeState interface which specifies
> that getChildNode would never return null
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira