com.aspose.pdf

Interfaces

Classes

Enums

Exceptions

com.aspose.pdf

Class AnnotationCollection

    • Constructor Detail

      • AnnotationCollection

        public AnnotationCollection(Page page)

        Constructor of AnnotationCollection. Creates annotation collection for annotations on the given page.

        Parameters:
        page - Parent page of annotations.
    • Method Detail

      • isSynchronized

        public boolean isSynchronized()

        Gets a value indicating whether access to the com.aspose.pdf.AnnotationCollection is synchronized (thread safe).

        Returns:
        boolean value
      • getSyncRoot

        public Object getSyncRoot()

        Gets an object that can be used to synchronize access to com.aspose.pdf.AnnotationCollection.

        Returns:
        Object for sinchronization
      • size

        public int size()

        Gets count of annotations in collection.

        Returns:
        int value
      • isReadOnly

        public boolean isReadOnly()

        Gets a value indicating if collection is readonly.

        Returns:
        boolean value
      • add

        public void add(Annotation annotation,
                        boolean considerRotation)

        Adds annotation to the collection. If page is rotated then annotation rectangle will be recalculated accordingly.

        Parameters:
        annotation - Annotation which shall be added.
        considerRotation - If true and if page is rotated then annotation position will be recaculated accroding to page rotation.
      • add

        public void add(Annotation annotation)

        Adds annotation to the collection.

        Parameters:
        annotation - Annotation which shall be added.
      • delete

        public void delete(int index)

        Deletes annotation from the collection by index.

        Parameters:
        index - Index of annotation which shall be deleted.
      • delete

        public void delete()

        Deletes all annotations from the collection.

      • copyTo

        public void copyTo(Annotation[] array,
                           int index)

        Copies array of annotations into collection.

        Parameters:
        array - Array to copy into collection.
        index - Starting index where colleciton wil lbe copied.
      • iterator

        public com.aspose.ms.System.Collections.IEnumerator<Annotation> iterator()

        Returns collection enumerator.

        Specified by:
        iterator in interface Iterable<Annotation>
        Returns:
        Enumerator object
      • accept

        public void accept(AnnotationSelector visitor)

        Accepts visitor to process annotation.

        Parameters:
        visitor - Annotation selector object.
      • delete

        public void delete(Annotation annotation)

        Deletes specified annotation from the collection.

        Parameters:
        annotation - Annotation which shall be deleted.
      • clear

        public void clear()

        Deletes all annotations from the collection.

      • contains

        public boolean contains(Annotation annotation)

        Checks if specified annotation belong to collection.

        Parameters:
        annotation - Annotation to be searched.
        Returns:
        boolean value
      • remove

        public boolean remove(Annotation annotation)

        Deletes specified annotation from the collection.

        Parameters:
        annotation - Annotation which shall be deleted.
        Returns:
        boolean value
      • get_Item

        public Annotation get_Item(int index)

        The index of the element to get.

        Parameters:
        index - The index value started from one.
        Returns:
        Annotation object