Implement a SubsetGenerator that generates all subsets of the characters of a string. For example, the subsets of the characters of the string "rum" are the eight strings

"rum", "ru", "rm", "r", "um", "u", "m", ""

Note that the subsets don't have to be substrings—for example, "rm" isn't a substring of "rum".

Complete the following files:

Use the following file:

import java.util.Collections;
import java.util.ArrayList;

   This program tests the subset generator.
public class SubsetGeneratorTester
   public static void main(String[] args)
      SubsetGenerator generator 
            = new SubsetGenerator("rum");
      ArrayList<String> subsets = generator.getSubsets();
      // Sort the result for checking 
      System.out.println("Expected: [, m, r, rm, ru, rum, u, um]");