*/
public static void main(String[] args) {
BinaryFileIndexSaver saver = new BinaryFileIndexSaver("out.bin", "writehere.bin");
CardIndex index2 = saver.readIndex();
PhoneCall call1 = new PhoneCall("777", 1, new GregorianCalendar(1999, 1, 1));
PhoneCall call2 = new PhoneCall("142", 2, new GregorianCalendar(2011, 1, 1));
PhoneCall call3 = new PhoneCall("777", 3, new GregorianCalendar(4555, 1, 1));
index2.addCall("3300052", call3);
index2.addCall("7555909", call2);
index2.addCall("3494090", call1);
for (Subscriber s : index2.keySet()) {
PriorityQueue<SubscriberEntry> col = index2.get(s);
for (SubscriberEntry se : col) {
System.out.println(se.toString());
}
}
ArrayList<SubscriberCallPair> al;
al = index2.getAllCalls("777");
for (SubscriberCallPair callPair : al) {
System.out.println(callPair.toString());
}