Class GenericExts

java.lang.Object
org.sblim.cimclient.GenericExts

public class GenericExts extends Object
Class GenericExts is responsible for generic initialization
  • Constructor Details

    • GenericExts

      public GenericExts()
  • Method Details

    • initClearArrayList

      public static <T> ArrayList<T> initClearArrayList(ArrayList<T> pAL)
      initArrayList : If arrayList is null then it will return the new arrayList of same type if it is not null then it will clear the arrayList
      Type Parameters:
      T - : Type Parameter
      Parameters:
      pAL - : ArrayList to be initialized
      Returns:
      ArrayList : initialized ArrayList
    • initArrayList

      public static <T> ArrayList<T> initArrayList(ArrayList<T> pAL)
      initArrayList : If arrayList is null then it will return the new arrayList of same type if it is not null then it will return the same arrayList
      Type Parameters:
      T - : Type Parameter
      Parameters:
      pAL - : ArrayList to be initialized
      Returns:
      ArrayList : initialized ArrayList
    • cloneVector

      public static <T> Vector<T> cloneVector(Vector<T> oldVec)
      cloneVector : Generic deep copy of the vector. If original vector is null then return value will also be null.
      Type Parameters:
      T - : Type of vector
      Parameters:
      oldVec - : The original vector.
      Returns:
      Vector : Deep copy of original vector.