return new RemoveParticipant(context, participantId);
} else if (coreOp instanceof CoreAddParticipant) {
ParticipantId participantId = ((CoreAddParticipant) coreOp).getParticipantId();
return new AddParticipant(context, participantId);
} else if (coreOp instanceof CoreWaveletDocumentOperation) {
CoreWaveletDocumentOperation waveletDocOp = (CoreWaveletDocumentOperation) coreOp;
return new WaveletBlipOperation(waveletDocOp.getDocumentId(),
new BlipContentOperation(context, waveletDocOp.getOperation()));
} else if (coreOp instanceof CoreNoOp) {
return new NoOp(context);
} else {
throw new IllegalArgumentException("unknown operation type");
}