conversationListener.deltaEnd();
}
} catch (OperationException e) {
throw new IllegalStateException("Operation failed to apply when generating events", e);
} finally {
conversation.removeListener(conversationListener);
wavelet.removeListener(waveletListener);
for (EventGeneratingDocumentHandler docHandler : docHandlers.values()) {
docHandler.doc.removeListener(docHandler);
}
}