Package org.waveprotocol.wave.federation.Proto.ProtocolWaveletOperation

Examples of org.waveprotocol.wave.federation.Proto.ProtocolWaveletOperation.MutateDocument


  public static Set<AttachmentId> getAttachemntIds(ProtocolWaveletDelta delta) {
    Set<AttachmentId> ids = new HashSet<AttachmentId>();
    for (int i=0; i < delta.getOperationCount(); i++) {
      ProtocolWaveletOperation op = delta.getOperation(i);
      if (op.hasMutateDocument()) {
        MutateDocument doc = op.getMutateDocument();
        for (int c = 0; c < doc.getDocumentOperation().getComponentCount(); c++) {
          Component comp = doc.getDocumentOperation().getComponent(c);
          ElementStart start = comp.getElementStart();
          if (ImageConstants.TAGNAME.equals(start.getType())) {
            for (int a=0; a < start.getAttributeCount(); a++) {
              Component.KeyValuePair attr = start.getAttribute(a);
              if (ImageConstants.ATTACHMENT_ATTRIBUTE.equals(attr.getKey())) {
View Full Code Here

TOP

Related Classes of org.waveprotocol.wave.federation.Proto.ProtocolWaveletOperation.MutateDocument

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.