I have a Map with key and value as key as "Date" value as a "Bean".
Suppose i have bean as
public class example{
private long id;
private String name;
private long date;
private String workAssigned;
//getters & setters
}
I got a list of bean values.
List<example> list = getDetails();
i am iterating and forming a map .
as
for(example e : list)
{
List<example> list=exampleMap.get(example.getDate());
if(list==null){
list = new ArrayList<example>();
exampleMap.put(example.getDate(), list);
}
list.add(e);
}
Now i got a map with date..
Now i need to write those values into xls.. I have done but i am getting horizontally like
Employee1 Id workAssigned
2016-04-15
bhavani 12345651 read
Julian Thomak 46546546 write
Shiva 54464646 read
2016-04-20
Bhavani 5479844 write
Shiva 4745654 read
But expected output:
---------------------------------------------------------
2016-04-15 2016-04-16
--------------------------------------------------------
Employee1 Id workAssigned id workassgigned
-------------------------------------------------------
bhavani 12345651 read 5479844 write
Julian Thomak 46546546 write
Shiva 54464646 read 4745654 read
sahu 1024158 read
Hope you undersatnd.. Can anyone please help me solve this..
