Class SparkDB.HMList

java.lang.Object
SparkDB.HMList
Enclosing class:
SparkDB

public class SparkDB.HMList extends Object
A bidirectional list between index value and String value
Author:
Morad Abdelrasheed Mokhtar Ali Gill
  • Constructor Details

    • HMList

      public HMList()
  • Method Details

    • add

      public void add(String in)
      Adds an element
      Parameters:
      in - Element to be added
    • multipleGet

      public ArrayList<Integer> multipleGet(String in, int iter)
      Get multiple indices that are linked with the same String value
      Parameters:
      in - The String value
      iter - How many indices to grab
      Returns:
    • edit

      public void edit(int i, String ns)
      Edits an entry based on its index value
      Parameters:
      i - Target Index Value
      ns - The new String value
    • get

      public String get(int i)
      Get String value based on its index
      Parameters:
      i - Target Index Value
      Returns:
      The String value that is linked to the input index value
    • delete

      public void delete(int i)
      Deletes an element
      Parameters:
      i - Target Index value to delete
    • toString

      public String toString()
      Overrides:
      toString in class Object