public Status getStatus() throws InvalidItemStateException {
Tree parent = getParentTree();
if (parent == null) {
return Status.EXISTING; // FIXME: return correct status for root. See also OAK-161
} else {
Status childStatus = parent.getChildStatus(getName());
if (childStatus == null) {
throw new InvalidItemStateException("Node is stale");
}
return childStatus;
}