Package com.aspose.words

Examples of com.aspose.words.NodeCollection


  public static void main(String[] args) throws Exception
  {
    Document doc = new Document("data/document.doc");

    // This gets a live collection of all shape nodes in the document.
    NodeCollection shapeCollection = doc.getChildNodes(NodeType.SHAPE, true);

    // Since we will be adding/removing nodes, it is better to copy all collection
    // into a fixed size array, otherwise iterator will be invalidated.
    Node[] shapes = shapeCollection.toArray();

    for (Node node : shapes)
    {
        Shape shape = (Shape)node;
        // Filter out all shapes that we don't need.
View Full Code Here


{
  public static void main(String[] args) throws Exception
  {
    Document doc = new Document("data/document.doc");
   
    NodeCollection shapes = doc.getChildNodes(NodeType.SHAPE, true);
    int imageIndex = 0;
    for (Shape shape : (Iterable<Shape>) shapes)
    {
      if (shape.hasImage())
      {
View Full Code Here

TOP

Related Classes of com.aspose.words.NodeCollection

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.