src/main/java/org/apache/sling/testing/mock/jcr/MockNode.java
private void addItemOrRemoveIfValueNull(ItemData itemData, Object value) throws RepositoryException {
        if (value == null) {
            getMockedSession().removeItem(itemData.getPath());
        }
        else {
            getMockedSession().addItem(itemData);
        }
        this.itemData.setIsChanged(true);
    }
/**
     * Adds or overwrites an item and marks the item value as changed.
     * If the given value is null, the item is removed instead.
     * @param itemData Item data
     * @throws RepositoryException
     */
Adds or overwrites an item and marks the item value as changed.
If the given value is null, the item is removed instead.
@param itemData Item data
@throws RepositoryException
Adds or overwrites an item and marks the item value as changed . If the given value is null the item is removed instead . @param itemData Item data @throws RepositoryException
private void addItemOrRemoveIfValueNull(ItemData itemData, Object value) throws RepositoryException {
        if (value == null) {
            getMockedSession().removeItem(itemData.getPath());
        }
        else {
            getMockedSession().addItem(itemData);
        }
        this.itemData.setIsChanged(true);
    }
private void addItemOrRemoveIfValueNull ( ItemData itemData , Object value ) throws RepositoryException { if ( value == null ) { getMockedSession ( ) . removeItem ( itemData . getPath ( ) ) ; } else { getMockedSession ( ) . addItem ( itemData ) ; } this . itemData . setIsChanged ( true ) ; }
Adds or overwrites an item and marks the item value as changed.
Adds or overwrites an item and marks the item value as changed .