Packages

 

com.aspose.cad

Class NonGenericList

    • Constructor Summary

      Constructors 
      Constructor and Description
      NonGenericList(com.aspose.ms.System.Collections.Generic.List list)
      Initializes a new instance of the NonGenericList class.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      int addItem(Object value)
      Adds an item to the list.
      void clear()
      Removes all items from the list.
      boolean contains(Object value)
      Determines whether the list contains a specific value.
      void copyTo(com.aspose.ms.System.Array array, int index)
      Copies the elements of the collection to an array, starting at a particular array index.
      Object get_Item(int index)
      Gets the element at the specified index.
      Object getSyncRoot()
      Gets an object that can be used to synchronize access to the collection.
      int indexOf(Object value)
      Determines the index of a specific item in the list.
      void insertItem(int index, Object value)
      Inserts an item to the list at the specified index.
      boolean isFixedSize()
      Gets a value indicating whether the list has a fixed size.
      boolean isReadOnly()
      Gets a value indicating whether the list is read-only.
      boolean isSynchronized()
      Gets a value indicating whether access to the collection is synchronized (thread safe).
      com.aspose.ms.System.Collections.IEnumerator iterator()
      Returns an enumerator that iterates through a collection.
      void removeAt(int index)
      Removes the list item at the specified index.
      void removeItem(Object value)
      Removes the first occurrence of a specific object from the list.
      void set_Item(int index, Object value)
      Sets the element at the specified index.
      int size()
      Gets the number of elements contained in the collection.
    • Constructor Detail

      • NonGenericList

        public NonGenericList(com.aspose.ms.System.Collections.Generic.List list)

        Initializes a new instance of the NonGenericList class.

        Parameters:
        list - The list - container of objects.
    • Method Detail

      • addItem

        public int addItem(Object value)

        Adds an item to the list.

        Specified by:
        addItem in interface com.aspose.ms.System.Collections.IList
        Parameters:
        value - The object to add to the list.
        Returns:
        The position into which the new element was inserted.
      • clear

        public void clear()

        Removes all items from the list.

        Specified by:
        clear in interface com.aspose.ms.System.Collections.IList
      • contains

        public boolean contains(Object value)

        Determines whether the list contains a specific value.

        Specified by:
        contains in interface com.aspose.ms.System.Collections.IList
        Parameters:
        value - The object to locate in the list.
        Returns:
        true if the object is found in the list; otherwise, false.
      • indexOf

        public int indexOf(Object value)

        Determines the index of a specific item in the list.

        Specified by:
        indexOf in interface com.aspose.ms.System.Collections.IList
        Parameters:
        value - The object to locate in the list.
        Returns:
        The index of value if found in the list; otherwise, -1.
      • insertItem

        public void insertItem(int index,
                               Object value)

        Inserts an item to the list at the specified index.

        Specified by:
        insertItem in interface com.aspose.ms.System.Collections.IList
        Parameters:
        index - The zero-based index at which value should be inserted.
        value - The object to insert into the list.
      • isFixedSize

        public boolean isFixedSize()

        Gets a value indicating whether the list has a fixed size.

        Specified by:
        isFixedSize in interface com.aspose.ms.System.Collections.IList
      • isReadOnly

        public boolean isReadOnly()

        Gets a value indicating whether the list is read-only.

        Specified by:
        isReadOnly in interface com.aspose.ms.System.Collections.IList
      • get_Item

        public Object get_Item(int index)

        Gets the element at the specified index.

        Specified by:
        get_Item in interface com.aspose.ms.System.Collections.IList
        Parameters:
        index - The index.
        Returns:
        The element
      • set_Item

        public void set_Item(int index,
                             Object value)

        Sets the element at the specified index.

        Specified by:
        set_Item in interface com.aspose.ms.System.Collections.IList
        Parameters:
        index - The index.
      • removeItem

        public void removeItem(Object value)

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

        Specified by:
        removeItem in interface com.aspose.ms.System.Collections.IList
        Parameters:
        value - The object to remove from the list.
      • removeAt

        public void removeAt(int index)

        Removes the list item at the specified index.

        Specified by:
        removeAt in interface com.aspose.ms.System.Collections.IList
        Parameters:
        index - The zero-based index of the item to remove.
      • copyTo

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

        Copies the elements of the collection to an array, starting at a particular array index.

        Specified by:
        copyTo in interface com.aspose.ms.System.Collections.ICollection
        Parameters:
        array - The one-dimensional array that is the destination of the elements copied from collection. The array must have zero-based indexing.
        index - The zero-based index in array at which copying begins.
      • size

        public int size()

        Gets the number of elements contained in the collection.

        Specified by:
        size in interface com.aspose.ms.System.Collections.ICollection
      • isSynchronized

        public boolean isSynchronized()

        Gets a value indicating whether access to the collection is synchronized (thread safe).

        Specified by:
        isSynchronized in interface com.aspose.ms.System.Collections.ICollection
      • getSyncRoot

        public Object getSyncRoot()

        Gets an object that can be used to synchronize access to the collection.

        Specified by:
        getSyncRoot in interface com.aspose.ms.System.Collections.ICollection
      • iterator

        public com.aspose.ms.System.Collections.IEnumerator iterator()

        Returns an enumerator that iterates through a collection.

        Specified by:
        iterator in interface com.aspose.ms.System.Collections.IEnumerable
        Specified by:
        iterator in interface Iterable
        Returns:
        An IEnumerator object that can be used to iterate through the collection.