private void addBookmarkEnd(int id, DocumentFragment docfrag) { CTMarkupRange markuprange = Context.getWmlObjectFactory().createCTMarkupRange(); markuprange.setId( BigInteger.valueOf(id ) ); Document tmpDoc = XmlUtils.marshaltoW3CDomDocument(markuprange); XmlUtils.treeCopy(tmpDoc.getDocumentElement(), docfrag); }
private void appendBookmarksToMove(Object child) { CTBookmark bm = (CTBookmark)XmlUtils.unwrap(child); JAXBElement<CTMarkupRange> jaxbBmEnd = null; CTMarkupRange bmEnd = null; bookmarksStartToMove.add(child); //The bookmarkEnd is put directly after a moved bookmarkStart in the paragraph. //the corresponding bookmarkEnd is later deleted //(this ensures that the bookmarkEnd isn't before the bookmarkStart bmEnd = Context.getWmlObjectFactory().createCTMarkupRange(); bmEnd.setId(bm.getId()); jaxbBmEnd = Context.getWmlObjectFactory().createPBookmarkEnd(bmEnd); bookmarksStartToMove.add(jaxbBmEnd); bookmarksEndToRemove.add(bm.getId()); }
mr.setId(ID); JAXBElement<CTMarkupRange> bmEnd = factory.createBodyBookmarkEnd(mr); p.getContent().add(bmEnd);
CTMarkupRange mr = Context.getWmlObjectFactory().createCTMarkupRange(); mr.setId(BigInteger.valueOf(newId)); JAXBElement<CTMarkupRange> bmEnd = Context.getWmlObjectFactory().createBodyBookmarkEnd(mr); paragraphs.add(bmEnd);
@Override public CTMarkupRange createBookmarkEnd(final CTBookmark bookmarkStart, final boolean isBlockBookmark) { CTMarkupRange mr = myFactory.createCTMarkupRange(); mr.setId(bookmarkStart.getId()); JAXBElement<CTMarkupRange> bmEnd = myFactory.createBodyBookmarkEnd(mr); if (isBlockBookmark) { myContentContainer.addContentElement(bmEnd); } else { // add as inline getP().getContent().add(bmEnd); } return mr; }
private CTMarkupRange generateBookmarkEnd() { CTMarkupRange markuprange = Context.getWmlObjectFactory().createCTMarkupRange(); markuprange.setId( BigInteger.valueOf(getBookmarkId().getAndIncrement() ) ); return markuprange; }
private void addBookmarkEnd(int id, DocumentFragment docfrag) { CTMarkupRange markuprange = Context.getWmlObjectFactory().createCTMarkupRange(); markuprange.setId( BigInteger.valueOf(id ) ); Document tmpDoc = XmlUtils.marshaltoW3CDomDocument(markuprange); XmlUtils.treeCopy(tmpDoc.getDocumentElement(), docfrag); }
private void appendBookmarksToMove(Object child) { CTBookmark bm = (CTBookmark)XmlUtils.unwrap(child); JAXBElement<CTMarkupRange> jaxbBmEnd = null; CTMarkupRange bmEnd = null; bookmarksStartToMove.add(child); //The bookmarkEnd is put directly after a moved bookmarkStart in the paragraph. //the corresponding bookmarkEnd is later deleted //(this ensures that the bookmarkEnd isn't before the bookmarkStart bmEnd = Context.getWmlObjectFactory().createCTMarkupRange(); bmEnd.setId(bm.getId()); jaxbBmEnd = Context.getWmlObjectFactory().createPBookmarkEnd(bmEnd); bookmarksStartToMove.add(jaxbBmEnd); bookmarksEndToRemove.add(bm.getId()); }
mr.setId(ID); JAXBElement<CTMarkupRange> bmEnd = factory.createBodyBookmarkEnd(mr); p.getContent().add(bmEnd);
CTMarkupRange mr = Context.getWmlObjectFactory().createCTMarkupRange(); mr.setId(BigInteger.valueOf(newId)); JAXBElement<CTMarkupRange> bmEnd = Context.getWmlObjectFactory().createBodyBookmarkEnd(mr); paragraphs.add(bmEnd);