com.aspose.slides

Interfaces

Classes

Exceptions

com.aspose.slides

Class TagCollection

  • java.lang.Object
    • com.aspose.slides.TagCollection
  • All Implemented Interfaces:
    com.aspose.ms.System.Collections.Generic.IGenericEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>, com.aspose.ms.System.Collections.ICollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>, com.aspose.ms.System.Collections.IEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>, IGenericCollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>, ITagCollection, java.lang.Iterable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>


    public final class TagCollection
    extends java.lang.Object
    implements ITagCollection

    Represents the collection of tags (user defined pairs of strings)

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int add(java.lang.String name, java.lang.String value)
      Adds a new tag to collection.
      void clear()
      Removes all tags from the collection.
      boolean contains(java.lang.String name)
      Determines whether the collection contains a specific name.
      void copyTo(com.aspose.ms.System.Array array, int index)
      Copies all elements from the collection into the specified array.
      java.lang.String get_Item(java.lang.String name)
      Returns or sets a key and a value pair of a tag.
      java.lang.String getNameByIndex(int index)
      Returns key of a tag at the specified index.
      java.lang.String[] getNamesOfTags()
      Returns names of tags.
      java.lang.Object getSyncRoot()
      Returns a synchronization root.
      java.lang.String getValueByIndex(int index)
      Returns value of a tag at the specified index.
      int indexOfName(java.lang.String name)
      Returns the zero-based index of the specified key in the collection.
      boolean isSynchronized()
      Returns a value indicating whether access to the collection is synchronized (thread-safe).
      com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>> iterator()
      Returns an enumerator that iterates through the collection.
      com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>> iteratorJava()
      Returns a java iterator for the entire collection.
      void remove(java.lang.String name)
      Removes the tag with a specified name from the collection.
      void removeAt(int index)
      Removes the tag at the specified index.
      void set_Item(java.lang.String name, java.lang.String value)
      Returns or sets a key and a value pair of a tag.
      int size()
      Returns a number of tags in the collectoin.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.lang.Iterable

        forEach, spliterator
    • Method Detail

      • size

        public final int size()

        Returns a number of tags in the collectoin. Read-only int.

        Specified by:
        size in interface com.aspose.ms.System.Collections.ICollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
      • add

        public final int add(java.lang.String name,
                             java.lang.String value)

        Adds a new tag to collection.

        Specified by:
        add in interface ITagCollection
        Parameters:
        name - The name of the tag.
        value - The value of the tag.
        Returns:
        The index of the added tag.
      • remove

        public final void remove(java.lang.String name)

        Removes the tag with a specified name from the collection.

        Specified by:
        remove in interface ITagCollection
        Parameters:
        name - The name of tag to remove.
      • indexOfName

        public final int indexOfName(java.lang.String name)

        Returns the zero-based index of the specified key in the collection.

        Specified by:
        indexOfName in interface ITagCollection
        Parameters:
        name - The name to locate in the collection.
        Returns:
        The zero-based index of key, if key is found in the collection; otherwise, -1.
      • contains

        public final boolean contains(java.lang.String name)

        Determines whether the collection contains a specific name.

        Specified by:
        contains in interface ITagCollection
        Parameters:
        name - The key to locate.
        Returns:
        True if the collection contains an tag with the specified key; otherwise, false.
      • removeAt

        public final void removeAt(int index)

        Removes the tag at the specified index.

        Specified by:
        removeAt in interface ITagCollection
        Parameters:
        index - The zero-based index of the tag to remove.
      • clear

        public final void clear()

        Removes all tags from the collection.

        Specified by:
        clear in interface ITagCollection
      • getValueByIndex

        public final java.lang.String getValueByIndex(int index)

        Returns value of a tag at the specified index.

        Specified by:
        getValueByIndex in interface ITagCollection
        Parameters:
        index - Index of a tag to return.
        Returns:
        Value of a tag.
      • getNameByIndex

        public final java.lang.String getNameByIndex(int index)

        Returns key of a tag at the specified index.

        Specified by:
        getNameByIndex in interface ITagCollection
        Parameters:
        index - Index of a tag to return.
        Returns:
        Key of a tag.
      • getNamesOfTags

        public final java.lang.String[] getNamesOfTags()

        Returns names of tags.

        Specified by:
        getNamesOfTags in interface ITagCollection
        Returns:
        Names of tags.
      • get_Item

        public final java.lang.String get_Item(java.lang.String name)

        Returns or sets a key and a value pair of a tag.

        Specified by:
        get_Item in interface ITagCollection
        Parameters:
        name - Key of a tag.
        Returns:
        Value of a tag.
      • set_Item

        public final void set_Item(java.lang.String name,
                                   java.lang.String value)

        Returns or sets a key and a value pair of a tag.

        Specified by:
        set_Item in interface ITagCollection
        Parameters:
        name - Key of a tag.
      • copyTo

        public final void copyTo(com.aspose.ms.System.Array array,
                                 int index)

        Copies all elements from the collection into the specified array.

        Specified by:
        copyTo in interface com.aspose.ms.System.Collections.ICollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
        Parameters:
        array - Array to fill.
        index - Starting position in target array.
      • isSynchronized

        public final boolean isSynchronized()

        Returns a value indicating whether access to the collection is synchronized (thread-safe). Read-only boolean.

        Specified by:
        isSynchronized in interface com.aspose.ms.System.Collections.ICollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
      • getSyncRoot

        public final java.lang.Object getSyncRoot()

        Returns a synchronization root. Read-only Object.

        Specified by:
        getSyncRoot in interface com.aspose.ms.System.Collections.ICollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
      • iterator

        public final com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>> iterator()

        Returns an enumerator that iterates through the collection.

        Specified by:
        iterator in interface com.aspose.ms.System.Collections.Generic.IGenericEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
        Specified by:
        iterator in interface com.aspose.ms.System.Collections.IEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
        Specified by:
        iterator in interface java.lang.Iterable<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
        Returns:
        A System.Collections.Generic.IEnumerator`1 that can be used to iterate through the collection.
      • iteratorJava

        public final com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>> iteratorJava()

        Returns a java iterator for the entire collection.

        Specified by:
        iteratorJava in interface IGenericCollection<com.aspose.ms.System.Collections.Generic.KeyValuePair<java.lang.String,java.lang.String>>
        Returns:
        An Iterator for the entire collection.