private class WebDavEventListener implements EventsListener {
public void handleEventsBeforeSave(Session session, Item item, List<Event> events)
throws RepositoryException {
for (Event e : events) {
if (e instanceof AddNodeEvent) {
AddNodeEvent event = (AddNodeEvent) e;
BrixNode node = wrapNode(event.getNewNode());
if (node instanceof ResourceNode) {
handleNewNode(node.getPath(), node, brix.wrapSession(session), false);
}
}
}