Class ArrayListTool


  • public class ArrayListTool
    extends java.lang.Object
    A tool class for ArrayLists
    Version:
    1.0
    Author:
    Andreas Mueller, IIT GmbH
    • Constructor Summary

      Constructors 
      Constructor Description
      ArrayListTool()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static int setFirstFreeOrExpand​(java.util.ArrayList list, java.lang.Object object)
      set the object in the list on the first position with value equals null or - if no free index exists - expand.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ArrayListTool

        public ArrayListTool()
    • Method Detail

      • setFirstFreeOrExpand

        public static int setFirstFreeOrExpand​(java.util.ArrayList list,
                                               java.lang.Object object)
        set the object in the list on the first position with value equals null or - if no free index exists - expand.
        Parameters:
        list - the list
        object - the object to insert
        Returns:
        the index for this object