final Map<String, RequestProperty> reqProperties,
final List<Modification> changes,
final VersioningConfiguration versioningConfiguration)
throws RepositoryException, PersistenceException {
final SlingPropertyValueHandler propHandler = new SlingPropertyValueHandler(
dateParser, new ReferenceParser(resolver.adaptTo(Session.class)), changes);
for (final RequestProperty prop : reqProperties.values()) {
if (prop.hasValues()) {
final Resource parent = deepGetOrCreateNode(resolver,
prop.getParentPath(), reqProperties, changes, versioningConfiguration);
final Node parentNode = parent.adaptTo(Node.class);
if ( parentNode != null ) {
checkoutIfNecessary(parentNode, changes, versioningConfiguration);
}
// skip jcr special properties
if (prop.getName().equals("jcr:primaryType")
|| prop.getName().equals("jcr:mixinTypes")) {
continue;
}
if (prop.isFileUpload()) {
uploadHandler.setFile(parent, prop, changes);
} else {
propHandler.setProperty(parent, prop);
}
}
}
}