本文整理汇总了Java中org.waveprotocol.box.common.comms.ProtocolSubmitResponse类的典型用法代码示例。如果您正苦于以下问题:Java ProtocolSubmitResponse类的具体用法?Java ProtocolSubmitResponse怎么用?Java ProtocolSubmitResponse使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ProtocolSubmitResponse类属于org.waveprotocol.box.common.comms包,在下文中一共展示了ProtocolSubmitResponse类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: viewSubmit
import org.waveprotocol.box.common.comms.ProtocolSubmitResponse; //导入依赖的package包/类
@Override
public String viewSubmit(final WaveletName wavelet, WaveletDelta delta, String channelId,
final SubmitCallback callback) {
ProtocolSubmitRequestJsoImpl submitRequest = ProtocolSubmitRequestJsoImpl.create();
submitRequest.setWaveletName(serialize(wavelet));
submitRequest.setDelta(serialize(wavelet, delta));
submitRequest.setChannelId(channelId);
final AsyncCallContext callContext = AsyncCallContext.start("SubmitRequest");
mux.submit(submitRequest, new SubmitResponseCallback() {
@Override
public void run(ProtocolSubmitResponse response) {
callContext.stop();
HashedVersion resultVersion = HashedVersion.unsigned(0);
if (response.hasHashedVersionAfterApplication()) {
resultVersion =
WaveletOperationSerializer.deserialize(response.getHashedVersionAfterApplication());
versions.updateHistory(wavelet, response.getHashedVersionAfterApplication());
}
callback.onSuccess(resultVersion, response.getOperationsApplied(), null, ResponseCode.OK);
}
});
// We don't support the getDebugProfiling thing anyway.
return null;
}
示例2: run
import org.waveprotocol.box.common.comms.ProtocolSubmitResponse; //导入依赖的package包/类
void run(ProtocolSubmitResponse response);
示例3: run
import org.waveprotocol.box.common.comms.ProtocolSubmitResponse; //导入依赖的package包/类
public void run(ProtocolSubmitResponse response);