com.aspose.slides

Interfaces

Classes

Exceptions

com.aspose.slides

Interface ISlideCollection

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      ISlide addClone(ISlide sourceSlide)
      Adds a copy of a specified slide to the end of the collection.
      ISlide addClone(ISlide sourceSlide, ILayoutSlide destLayout)
      Adds a copy of a specified slide to the end of the collection.
      ISlide addClone(ISlide sourceSlide, IMasterSlide destMaster, boolean allowCloneMissingLayout)
      Adds a copy of a specified source slide to the end of the collection.
      ISlide addEmptySlide(ILayoutSlide layout)
      Adds a new empty slide to the end of the collection.
      ISlide[] addFromHtml(java.io.InputStream htmlStream)
      Creates slides from HTML text and adds them to the end of the collection.
      ISlide[] addFromHtml(java.io.InputStream htmlStream, IExternalResourceResolver resolver, java.lang.String uri)
      Creates slides from HTML text and adds them to the end of the collection.
      ISlide[] addFromHtml(java.lang.String htmlText)
      Creates slides from HTML text and adds them to the end of the collection.
      ISlide[] addFromHtml(java.lang.String htmlText, IExternalResourceResolver resolver, java.lang.String uri)
      Creates slides from HTML text and adds them to the end of the collection.
      ISlide get_Item(int index)
      Gets the element at the specified index.
      int indexOf(ISlide slide)
      Returns an index of the specified slide in the collection.
      ISlide insertClone(int index, ISlide sourceSlide)
      Inserts a copy of a specified slide to specified position of the collection.
      ISlide insertClone(int index, ISlide sourceSlide, ILayoutSlide destLayout)
      Inserts a copy of a specified slide to specified position of the collection.
      ISlide insertClone(int index, ISlide sourceSlide, IMasterSlide destMaster, boolean allowCloneMissingLayout)
      Inserts a copy of a specified source slide to specified position of the collection.
      ISlide insertEmptySlide(int index, ILayoutSlide layout)
      Inserts a copy of a specified slide to specified position of the collection.
      ISlide[] insertFromHtml(int index, java.io.InputStream htmlStream)
      Creates slides from HTML text and inserts them to the collection at the specified position.
      ISlide[] insertFromHtml(int index, java.io.InputStream htmlStream, IExternalResourceResolver resolver, java.lang.String uri)
      Creates slides from HTML text and inserts them to the collection at the specified position.
      ISlide[] insertFromHtml(int index, java.lang.String htmlText)
      Creates slides from HTML text and inserts them to the collection at the specified position.
      ISlide[] insertFromHtml(int index, java.lang.String htmlText, IExternalResourceResolver resolver, java.lang.String uri)
      Creates slides from HTML text and inserts them to the collection at the specified position.
      void remove(ISlide value)
      Removes the first occurrence of a specific object from the collection.
      void removeAt(int index)
      Removes the element at the specified index of the collection.
      void reorder(int index, ISlide... slides)
      Moves slides from the collection to the specified position.
      void reorder(int index, ISlide slide)
      Moves slide from the collection to the specified position.
      ISlide[] toArray()
      Creates and returns an array with all slides in it.
      ISlide[] toArray(int startIndex, int count)
      Creates and returns an array with all slides from the specified range in it.
      • Methods inherited from interface com.aspose.ms.System.Collections.Generic.IGenericEnumerable

        iterator
      • Methods inherited from interface com.aspose.ms.System.Collections.ICollection

        copyTo, getSyncRoot, isSynchronized, size
      • Methods inherited from interface java.lang.Iterable

        forEach, spliterator
    • Method Detail

      • get_Item

        ISlide get_Item(int index)

        Gets the element at the specified index. Read-only ISlide.

      • insertClone

        ISlide insertClone(int index,
                           ISlide sourceSlide)

        Inserts a copy of a specified slide to specified position of the collection.

        Parameters:
        index - Index of new slide.
        sourceSlide - Slide to clone.


        When cloning a slide between different presentations slide's master can be cloned too. Internal registry is used to track automatically cloned masters to prevent creation of multiple clones of the same master slide. Manual cloning of master slides will be neither prevented nor registered. If you need more control over cloning process use insertClone(int,ISlide,ILayoutSlide) or insertClone(int,ISlide,IMasterSlide,boolean) for cloning slides and IMasterSlideCollection.addClone(IMasterSlide) for cloning masters.

        Returns:
        Inserted slide.
      • addEmptySlide

        ISlide addEmptySlide(ILayoutSlide layout)

        Adds a new empty slide to the end of the collection.

        Parameters:
        layout - Layout for a slide.
        Returns:
        Added slide.
      • insertEmptySlide

        ISlide insertEmptySlide(int index,
                                ILayoutSlide layout)

        Inserts a copy of a specified slide to specified position of the collection.

        Parameters:
        index - Index of a new slide.
        layout - Layout for a slide.
        Returns:
        Inserted slide.
      • addClone

        ISlide addClone(ISlide sourceSlide,
                        ILayoutSlide destLayout)

        Adds a copy of a specified slide to the end of the collection.

        Parameters:
        sourceSlide - Slide to clone.
        destLayout - Layout slide for a new slide.
        Returns:
        New slide.
      • insertClone

        ISlide insertClone(int index,
                           ISlide sourceSlide,
                           ILayoutSlide destLayout)

        Inserts a copy of a specified slide to specified position of the collection.

        Parameters:
        index - Index of new slide.
        sourceSlide - Slide to clone.
        destLayout - Layout slide for a new slide.
        Returns:
        Inserted slide.
      • addClone

        ISlide addClone(ISlide sourceSlide,
                        IMasterSlide destMaster,
                        boolean allowCloneMissingLayout)

        Adds a copy of a specified source slide to the end of the collection. Appropriate layout will be selected automatically from the specified master (appropriate layout is the layout with the same Type or Name as of layout of the source slide). If there is no appropriate layout then layout of the source slide will be cloned (if allowCloneMissingLayout is true) or PptxEditException will be thrown (if allowCloneMissingLayout is false).

        Parameters:
        sourceSlide - Slide to clone.
        destMaster - Master slide for a new slide.
        allowCloneMissingLayout - If there is no appropriate layout in specified master then layout of the source slide will be cloned (if allowCloneMissingLayout is true) or PptxEditException will be thrown (if allowCloneMissingLayout is false).
        Returns:
        New slide.
        Throws:
        PptxEditException - Thrown if there is no appropriate layout in specified master and allowCloneMissingLayout is false.
      • insertClone

        ISlide insertClone(int index,
                           ISlide sourceSlide,
                           IMasterSlide destMaster,
                           boolean allowCloneMissingLayout)

        Inserts a copy of a specified source slide to specified position of the collection. Appropriate layout will be selected automatically from the specified master (appropriate layout is the layout with the same Type or Name as of layout of the source slide). If there is no appropriate layout then layout of the source slide will be cloned (if allowCloneMissingLayout is true) or PptxEditException will be thrown (if allowCloneMissingLayout is false).

        Parameters:
        index - Index of new slide.
        sourceSlide - Slide to clone.
        destMaster - Master slide for a new slide.
        allowCloneMissingLayout - If there is no appropriate layout in specified master then layout of the source slide will be cloned (if allowCloneMissingLayout is true) or PptxEditException will be thrown (if allowCloneMissingLayout is false).
        Returns:
        Inserted slide.
        Throws:
        PptxEditException - Thrown if there is no appropriate layout in specified master and allowCloneMissingLayout is false.
      • remove

        void remove(ISlide value)

        Removes the first occurrence of a specific object from the collection.

        Parameters:
        value - The slide to remove from the collection.
      • removeAt

        void removeAt(int index)

        Removes the element at the specified index of the collection.

        Parameters:
        index - The zero-based index of the element to remove.


        Not implemented yet.

      • toArray

        ISlide[] toArray()

        Creates and returns an array with all slides in it.

        Returns:
        Array of ISlide
      • toArray

        ISlide[] toArray(int startIndex,
                         int count)

        Creates and returns an array with all slides from the specified range in it.

        Parameters:
        startIndex - An index of a first slide to add.
        count - A number of slides to add.
        Returns:
        Array of ISlide
      • reorder

        void reorder(int index,
                     ISlide slide)

        Moves slide from the collection to the specified position.

        Parameters:
        index - Target index.
        slide - Slide to move.
      • reorder

        void reorder(int index,
                     ISlide... slides)

        Moves slides from the collection to the specified position. Slides will be placed starting from index in order they appear in list.

        Parameters:
        index - Target index.
        slides - Slides to move.
      • indexOf

        int indexOf(ISlide slide)

        Returns an index of the specified slide in the collection.

        Parameters:
        slide - Slide to find.
        Returns:
        Index of a slide or -1 if slide not from this collection.
      • addFromHtml

        ISlide[] addFromHtml(java.lang.String htmlText,
                             IExternalResourceResolver resolver,
                             java.lang.String uri)

        Creates slides from HTML text and adds them to the end of the collection.

        Parameters:
        htmlText - Html to add.
        resolver - A callback object used to fetch external objects. If this parameter is null all external objects will be ignored.
        uri - An URI of the specified HTML. Used to resolve relative links.
        Returns:
        Added slides.
      • addFromHtml

        ISlide[] addFromHtml(java.lang.String htmlText)

        Creates slides from HTML text and adds them to the end of the collection.

        Parameters:
        htmlText - Html to add.
        Returns:
        Added slides
      • addFromHtml

        ISlide[] addFromHtml(java.io.InputStream htmlStream,
                             IExternalResourceResolver resolver,
                             java.lang.String uri)

        Creates slides from HTML text and adds them to the end of the collection.

        Parameters:
        htmlStream - A Stream object which will be used as a source of a HTML file.
        resolver - A callback object used to fetch external objects. If this parameter is null all external objects will be ignored.
        uri - An URI of the specified HTML. Used to resolve relative links.
        Returns:
        Added slides.
      • addFromHtml

        ISlide[] addFromHtml(java.io.InputStream htmlStream)

        Creates slides from HTML text and adds them to the end of the collection.

        Parameters:
        htmlStream - A Stream object which will be used as a source of a HTML file.
        Returns:
        Added slides
      • insertFromHtml

        ISlide[] insertFromHtml(int index,
                                java.lang.String htmlText,
                                IExternalResourceResolver resolver,
                                java.lang.String uri)

        Creates slides from HTML text and inserts them to the collection at the specified position.

        Parameters:
        index - Position to insert.
        htmlText - Html to add.
        resolver - A callback object used to fetch external objects. If this parameter is null all external objects will be ignored.
        uri - An URI of the specified HTML. Used to resolve relative links.
        Returns:
        Added slides.
      • insertFromHtml

        ISlide[] insertFromHtml(int index,
                                java.lang.String htmlText)

        Creates slides from HTML text and inserts them to the collection at the specified position.

        Parameters:
        index - Position to insert.
        htmlText - Html to add.
        Returns:
        Added slides
      • insertFromHtml

        ISlide[] insertFromHtml(int index,
                                java.io.InputStream htmlStream,
                                IExternalResourceResolver resolver,
                                java.lang.String uri)

        Creates slides from HTML text and inserts them to the collection at the specified position.

        Parameters:
        index - Position to insert.
        htmlStream - A Stream object which will be used as a source of a HTML file.
        resolver - A callback object used to fetch external objects. If this parameter is null all external objects will be ignored.
        uri - An URI of the specified HTML. Used to resolve relative links.
        Returns:
        Added slides.
      • insertFromHtml

        ISlide[] insertFromHtml(int index,
                                java.io.InputStream htmlStream)

        Creates slides from HTML text and inserts them to the collection at the specified position.

        Parameters:
        index - Position to insert.
        htmlStream - A Stream object which will be used as a source of a HTML file.
        Returns:
        Added slides