// check if import target is writable, not-locked and checked-out.
int options = ItemStateValidator.CHECK_ACCESS | ItemStateValidator.CHECK_LOCK | ItemStateValidator.CHECK_VERSIONING;
session.getValidator().checkIsWritable(importTarget, options);
refTracker = new ReferenceChangeTracker();
parents = new Stack<NodeState>();
parents.push(importTarget);
} catch (ItemNotFoundException e) {
throw new PathNotFoundException(LogUtil.safeGetJCRPath(parentPath, session.getPathResolver()));
}