use of org.apache.jackrabbit.core.xml.WorkspaceImporter in project jackrabbit by apache.
the class WorkspaceImpl method getImportContentHandler.
/**
* {@inheritDoc}
*/
public ContentHandler getImportContentHandler(String parentAbsPath, int uuidBehavior) throws PathNotFoundException, ConstraintViolationException, VersionException, LockException, RepositoryException {
// check state of this instance
sanityCheck();
Path parentPath;
try {
parentPath = context.getQPath(parentAbsPath).getNormalizedPath();
} catch (NameException e) {
String msg = "invalid path: " + parentAbsPath;
log.debug(msg);
throw new RepositoryException(msg, e);
}
if (!parentPath.isAbsolute()) {
throw new RepositoryException("not an absolute path: " + parentAbsPath);
}
Importer importer = new WorkspaceImporter(parentPath, this, context, uuidBehavior, wspConfig.getImportConfig());
return new ImportHandler(importer, getSession());
}
Aggregations