java.lang.Object
com.aspose.words.RevisionsView
public class RevisionsView
- extends java.lang.Object
Utility class containing constants.
Allows to specify whether to work with the original or revised version of a document.
Example:
Shows how to switch between the revised and the original view of a document.
Document doc = new Document(getMyDir() + "Revisions at list levels.docx");
doc.updateListLabels();
ParagraphCollection paragraphs = doc.getFirstSection().getBody().getParagraphs();
Assert.assertEquals("1.", paragraphs.get(0).getListLabel().getLabelString());
Assert.assertEquals("a.", paragraphs.get(1).getListLabel().getLabelString());
Assert.assertEquals("", paragraphs.get(2).getListLabel().getLabelString());
// View the document object as if all the revisions are accepted. Currently supports list labels.
doc.setRevisionsView(RevisionsView.FINAL);
Assert.assertEquals("", paragraphs.get(0).getListLabel().getLabelString());
Assert.assertEquals("1.", paragraphs.get(1).getListLabel().getLabelString());
Assert.assertEquals("a.", paragraphs.get(2).getListLabel().getLabelString());
Field Summary |
static final int | ORIGINAL = 0 | |
Specifies original version of a document.
|
static final int | FINAL = 1 | |
Specifies revised version of a document.
|
ORIGINAL = 0 | |
public static final int ORIGINAL |
-
Specifies original version of a document.
FINAL = 1 | |
public static final int FINAL |
-
Specifies revised version of a document.
See Also:
Aspose.Words Documentation - the home page for the Aspose.Words Product Documentation.
Aspose.Words Support Forum - our preferred method of support.