class LightWeightLinkedSet extends LightWeightHashSet<T> {

  @Override
  @SuppressWarnings("unchecked")
  public <U> U[] toArray(U[] a) {
    if (a == null) {
      throw new NullPointerException("Input array can not be null");
    }
    if (a.length < size) {
      a = (U[]) java.lang.reflect.Array
          .newInstance(a.getClass().getComponentType(), size);
    }
    int currentIndex = 0;
    DoubleLinkedElement<T> current = head;
    while (current != null) {
      T curr = current.element;
      a[currentIndex++] = (U) curr;
      current = current.after;
    }
    return a;
  }

  public  LightWeightLinkedSet(int initCapacity, float maxLoadFactor,
      float minLoadFactor);
  public  LightWeightLinkedSet();

}