[ 
https://issues.apache.org/jira/browse/OAK-1178?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13821526#comment-13821526
 ] 

angela commented on OAK-1178:
-----------------------------

that might be... i had another look at the MemoryNodeBuilder and wondered why 
#isNew() is implemented as:

{code}
    @Override
    public boolean isNew() {
        return !isRoot() && !parent.base().hasChildNode(name) && 
parent.hasChildNode(name);
    }
{code}

instead of just writing:

{code}
    return !base().exists();
{code}

there is most probably a reason for this, but just from the methods available i 
would have expected that this simplified version would reveal if there exists a 
persisted base-state.  



> MutableTree#isNew: replace implementation by NodeBuilder#isNew 
> ---------------------------------------------------------------
>
>                 Key: OAK-1178
>                 URL: https://issues.apache.org/jira/browse/OAK-1178
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: core
>            Reporter: angela
>            Assignee: Jukka Zitting
>             Fix For: 0.12
>
>         Attachments: OAK-1178.patch
>
>
> Similar to the issue described in OAK-1177 we may consider replacing the 
> implementation of MutableTree#isNew by the corresponding call on the 
> NodeBuilder.
> See also OAK-947.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to