com.aspose.slides

Interfaces

Classes

Exceptions

com.aspose.slides

Interface IParagraphCollection

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      void add(IParagraph value)
      Adds a Paragraph to the end of collection.
      int add(IParagraphCollection value)
      Adds a content of ParagraphCollection to the end of collection.
      void addFromHtml(java.lang.String text)
      Adds text from specified html string to the collection.
      void addFromHtml(java.lang.String text, IExternalResourceResolver resolver, java.lang.String uri)
      Adds text from specified html string to the collection.
      void clear()
      Removes all elements from the collection.
      java.lang.String exportToHtml(int firstParagraphIndex, int paragraphsCount, ITextToHtmlConversionOptions options)
      Converts specifying paragraphs to the HTML and returns it as String object.
      IParagraph get_Item(int index)
      Gets the element at the specified index.
      int getCount()
      Gets the number of elements actually contained in the collection.
      void insert(int index, IParagraph value)
      Inserts a Paragraph into the collection at the specified index.
      void insert(int index, IParagraphCollection value)
      Inserts a content of ParagraphCollection into the collection at the specified index.
      boolean remove(IParagraph item)
      Removes the first occurrence of a specific paragraph.
      void removeAt(int index)
      Removes the element at the specified index of the collection.
      • Methods inherited from interface com.aspose.ms.System.Collections.Generic.IGenericEnumerable

        iterator
      • Methods inherited from interface java.lang.Iterable

        forEach, spliterator
    • Method Detail

      • get_Item

        IParagraph get_Item(int index)

        Gets the element at the specified index.

      • getCount

        int getCount()

        Gets the number of elements actually contained in the collection. Read-only int.

      • add

        void add(IParagraph value)

        Adds a Paragraph to the end of collection.

        Parameters:
        value - The Paragraph to be added to the end of the collection.
      • add

        int add(IParagraphCollection value)

        Adds a content of ParagraphCollection to the end of collection.

        Parameters:
        value - The ParagraphCollection to be added to the end of the collection.
        Returns:
        The index at which the Paragraph has been added or -1 if there are nothing to add.
      • insert

        void insert(int index,
                    IParagraph value)

        Inserts a Paragraph into the collection at the specified index.

        Parameters:
        index - The zero-based index at which Paragraph should be inserted.
        value - The Paragraph to insert.
      • insert

        void insert(int index,
                    IParagraphCollection value)

        Inserts a content of ParagraphCollection into the collection at the specified index.

        Parameters:
        index - The zero-based index at which paragraphs should be inserted.
        value - The paragraphs to insert.
      • clear

        void clear()

        Removes all elements 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.
      • remove

        boolean remove(IParagraph item)

        Removes the first occurrence of a specific paragraph.

        Parameters:
        item - The paragraph to remove from collection.
        Returns:
        true if item was successfully removed; otherwise, false.
      • addFromHtml

        void addFromHtml(java.lang.String text)

        Adds text from specified html string to the collection.

        Parameters:
        text - HTML text.
      • addFromHtml

        void addFromHtml(java.lang.String text,
                         IExternalResourceResolver resolver,
                         java.lang.String uri)

        Adds text from specified html string to the collection.

        Parameters:
        text - HTML text.
        resolver - Resolver callback object which resolves URIs and fetches referrenced objects.
        uri - URI for adding HTML document. Used for resolving relative links.


        Specifying resolver can potentially introduce a vulnurability. Use with caution.
      • exportToHtml

        java.lang.String exportToHtml(int firstParagraphIndex,
                                      int paragraphsCount,
                                      ITextToHtmlConversionOptions options)

        Converts specifying paragraphs to the HTML and returns it as String object.

        Parameters:
        firstParagraphIndex - Index of paragraph.
        paragraphsCount - Count of paragraphs.
        options - ITextToHtmlConversionOptions object.
        Returns:
        Generated HTML.